Skip to content

sycl: support reordered Q4_K/Q5_K/Q6_K MoE MUL_MAT_ID#24452

Merged
ggerganov merged 2 commits into
ggml-org:masterfrom
newjordan:sycl-moe-reorder-ready
Jun 16, 2026
Merged

sycl: support reordered Q4_K/Q5_K/Q6_K MoE MUL_MAT_ID#24452
ggerganov merged 2 commits into
ggml-org:masterfrom
newjordan:sycl-moe-reorder-ready

Conversation

@newjordan

@newjordan newjordan commented Jun 11, 2026

Copy link
Copy Markdown
Contributor

Extends the existing SYCL MoE mul_mat_id reorder path to Q6_K expert weights.

This completes reordered MoE coverage for mixed K-quant MoE models whose down-projection experts are Q6_K. Existing Q4_K/Q5_K behavior is unchanged.

Validation:

  • test-backend-ops test -o MUL_MAT_ID: 714/714
  • Q5_K_M PPL spot check: unchanged
  • Local Arc Pro B70 NX2 decode: Q5_K_M 81.7 -> 85.8 t/s, Q4_K_M 85.7 -> 91.0 t/s

Requirements:

  • I have read and agree with the contributing guidelines
  • AI usage disclosure: YES - AI assisted with local preflight/test execution and PR preparation; the contributor reviewed the code, validation, and submitted content.

Extend reordered-weight handling to fused MoE MUL_MAT_ID for Q4_K and Q5_K expert tensors and add Q5_K reordered DMMV coverage. Unsupported 3D reorder cases now fall back instead of aborting.
@newjordan newjordan requested a review from a team as a code owner June 11, 2026 03:47
@github-actions github-actions Bot added ggml changes relating to the ggml tensor library for machine learning SYCL https://en.wikipedia.org/wiki/SYCL - GPU programming language labels Jun 11, 2026

@arthw arthw 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.

It's good job!

Thank you!

@newjordan newjordan changed the title sycl: support reordered Q4_K and Q5_K MoE MUL_MAT_ID sycl: support reordered Q4_K/Q5_K/Q6_K MoE MUL_MAT_ID Jun 12, 2026
@newjordan

Copy link
Copy Markdown
Contributor Author

Q6 was not fused in the previous PR, and incorporating it had a trickle down speed increase.

@arthw arthw 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.

It's good job!

For Qwen3.6-35B-A3B-Q4_K_M.gguf on B60 Ubuntu 24.04:

Test fa Base t/s Primary t/s Increase Rate (Primary vs Base)
pp512 0 722.87 722.62 -0.03%
pp512 1 711.10 693.31 -2.50%
tg128 0 62.84 68.79 9.47%
tg128 1 62.95 68.95 9.53%

Thank you!

@arthw arthw added the merge ready A maintainer can use this label to indicate that they consider the changes final and ready to merge. label Jun 16, 2026
@ggerganov ggerganov merged commit ac79caa into ggml-org:master Jun 16, 2026
31 of 54 checks passed
papamoose pushed a commit to papamoose/llama.cpp that referenced this pull request Jun 27, 2026
* sycl: support reordered Q4_K and Q5_K MoE MUL_MAT_ID

Extend reordered-weight handling to fused MoE MUL_MAT_ID for Q4_K and Q5_K expert tensors and add Q5_K reordered DMMV coverage. Unsupported 3D reorder cases now fall back instead of aborting.

* sycl: extend MoE reorder to Q6_K mul_mat_id
adrianhoehne pushed a commit to adrianhoehne/llama.cpp that referenced this pull request Jul 5, 2026
* sycl: support reordered Q4_K and Q5_K MoE MUL_MAT_ID

Extend reordered-weight handling to fused MoE MUL_MAT_ID for Q4_K and Q5_K expert tensors and add Q5_K reordered DMMV coverage. Unsupported 3D reorder cases now fall back instead of aborting.

* sycl: extend MoE reorder to Q6_K mul_mat_id
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ggml changes relating to the ggml tensor library for machine learning merge ready A maintainer can use this label to indicate that they consider the changes final and ready to merge. SYCL https://en.wikipedia.org/wiki/SYCL - GPU programming language

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants