Skip to content

perf(qwen35): add SpecLA factor-capture speculative decoding - #606

Draft
Graffioh wants to merge 3 commits into
Luce-Org:mainfrom
Graffioh:codex/qwen35-specla-current-main
Draft

perf(qwen35): add SpecLA factor-capture speculative decoding#606
Graffioh wants to merge 3 commits into
Luce-Org:mainfrom
Graffioh:codex/qwen35-specla-current-main

Conversation

@Graffioh

@Graffioh Graffioh commented Aug 13, 2026

Copy link
Copy Markdown
Contributor

Current gain over main

Qwen3.6-27B Q4_K_M target, Q8_0 DFlash draft, DDTree budget 22, top-k 4, tau=6, ten HumanEval-style prompts, and 128 generated tokens:

Configuration Mean decode throughput
Current main 25.14 tok/s
SpecLA 27.19 tok/s

SpecLA gain over current main: +8.2%.

@Graffioh
Graffioh force-pushed the codex/qwen35-specla-current-main branch from 27417ca to 5f38668 Compare August 13, 2026 10:55
@Graffioh

Copy link
Copy Markdown
Contributor Author

@cubic-dev-ai review this PR

@cubic-dev-ai

cubic-dev-ai Bot commented Aug 14, 2026

Copy link
Copy Markdown
Contributor

@cubic-dev-ai review this PR

@Graffioh I have started the AI code review. It will take a few minutes to complete.

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

1 issue found across 33 files

Prompt for AI agents (unresolved issues)

Check if these issues are valid — if so, understand the root cause of each and fix them. If appropriate, use sub-agents to investigate and fix each issue separately.


<file name="server/src/qwen35/qwen35_dflash_target.cpp">

<violation number="1" location="server/src/qwen35/qwen35_dflash_target.cpp:609">
P2: The SpecLA bank-rotation / `specla_compact_fused` / `specla_flush_raw_fused` logic is copied nearly verbatim between this file and `server/test/test_dflash.cpp`. `rollback_to_tree` (walked_sibling compaction + `current_bank`/`old_pending_bank` rotation + `pending_count` update), `finish_speculative_state` (bank selection via `specla_pending_bank` + `specla_flush_raw_fused`), and `rollback_to_specla` (bank toggle + count) each have a hand-maintained mirror in the bench harness. These are the two most state-sensitive routines in the PR; any divergence between the production target and the harness (e.g. the `ne` bounds, channel mapping, or bank-toggle logic) silently changes acceptance behavior. Pull the shared commit/flush helpers into a common function (e.g. in `specla_commit_cuda.h/.cu`) and have both call sites invoke it.</violation>
</file>

Reply with feedback, questions, or to request a fix.

Re-trigger cubic

Comment thread server/deps/llama.cpp/ggml/src/ggml.c
Comment thread server/src/common/dflash_target.h
Comment thread server/src/qwen35/qwen35_target_graph.cpp
Comment thread server/src/common/specla_commit_cuda.h Outdated
Comment thread server/src/common/ddtree.cpp
Comment thread server/test/test_dflash.cpp
Comment thread server/test/test_delta_net_specla.cpp
Comment thread server/test/test_delta_net_specla.cpp Outdated
Comment thread server/src/common/ddtree.cpp Outdated
Comment thread server/deps/llama.cpp/ggml/src/ggml.c Outdated
@Graffioh
Graffioh force-pushed the codex/qwen35-specla-current-main branch from 5f38668 to e7dc8f0 Compare August 15, 2026 07:11
@Graffioh
Graffioh force-pushed the codex/qwen35-specla-current-main branch from e7dc8f0 to c775f9e Compare August 15, 2026 07:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant