From cf711918e273e231d1155a80e0f33aff669ee187 Mon Sep 17 00:00:00 2001 From: Samuel Oliveira Alves <107287165+SamuelOliveirads@users.noreply.github.com> Date: Thu, 13 Aug 2026 13:02:08 -0300 Subject: [PATCH] Synch DFlash Tokens ID (#2303) * llama: synchronize DFlash argmax readback * llama: synchronize DFlash token access --- src/llama.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/llama.cpp b/src/llama.cpp index 4e477a55..7945d9db 100644 --- a/src/llama.cpp +++ b/src/llama.cpp @@ -11729,6 +11729,8 @@ float * llama_get_logits_ith(struct llama_context * ctx, int32_t i) { } llama_token llama_get_dflash_draft_token_ith(struct llama_context * ctx, int32_t i) { + llama_synchronize(ctx); + if ((size_t) i >= ctx->dflash.draft_tokens.size()) { return LLAMA_TOKEN_NULL; }