Skip to content

[CPU] Add CPU FP8 W8A8 linear/MoE support - #49942

Merged
bigPYJ1151 merged 5 commits into
vllm-project:mainfrom
yuwenzho:cpu-fp8-w8a8-linear-moe
Sep 18, 2026
Merged

bigPYJ1151 merged 5 commits into
vllm-project:mainfrom
yuwenzho:cpu-fp8-w8a8-linear-moe

Conversation

@yuwenzho

@yuwenzho yuwenzho commented Jul 27, 2026 •

Copy link
Copy Markdown
Contributor

Purpose

Support FP8 W8A8 Linear and MoE for Intel DMR CPUs.

Test Plan

Kernel tests:

  • python -m pytest tests/kernels/moe/test_cpu_quant_fused_moe.py -v
  • python -m pytest tests/kernels/quantization/test_cpu_fp8_scaled_mm.py -v

Validated models:

  • RedHatAI/Meta-Llama-3.1-8B-Instruct-FP8-dynamic (dense, per-channel weight / dynamic per-token act): CPUFP8W8A8ScaledMMLinearKernel
  • Qwen/Qwen3.5-35B-A3B-FP8 (MoE, block-wise 128x128 weight / dynamic act): CPUFp8W8A8BlockScaledMMKernel, CPUExpertsFp8W8A8
  • deepseek-ai/DeepSeek-R1 (MoE + MLA, block-wise 128x128 weight / dynamic act): CPUFp8W8A8BlockScaledMMKernel, CPUExpertsFp8W8A8

Test Result

python -m pytest tests/kernels/moe/test_cpu_quant_fused_moe.py -v : 185 passed
python -m pytest tests/kernels/quantization/test_cpu_fp8_scaled_mm.py -v: 190 passed

E2E Qwen/Qwen3.5-35B-A3B-FP8 gsm8k on DMR: 0.802


Essential Elements of an Effective PR Description Checklist
  • The purpose of the PR, such as "Fix some issue (link existing issues this PR will resolve)".
  • The test plan, such as providing test command.
  • The test results, such as pasting the results comparison before and after, or e2e results
  • (Optional) The necessary documentation update, such as updating supported_models.md and examples for a new model.

@mergify mergify Bot added ci/build cpu Related to CPU backends labels Jul 27, 2026
@mergify

mergify Bot commented Jul 27, 2026

Copy link
Copy Markdown
Contributor

This pull request has merge conflicts that must be resolved before it can be
merged. Please rebase the PR, @yuwenzho.

https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/working-with-forks/syncing-a-fork

@mergify mergify Bot added the needs-rebase label Jul 27, 2026
@yuwenzho
yuwenzho force-pushed the cpu-fp8-w8a8-linear-moe branch 3 times, most recently from 76cf681 to bed9c5a Compare August 11, 2026 01:51
@mergify mergify Bot removed the needs-rebase label Aug 11, 2026
@mergify

mergify Bot commented Aug 19, 2026

Copy link
Copy Markdown
Contributor

This pull request has merge conflicts that must be resolved before it can be
merged. Please rebase the PR, @yuwenzho.

https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/working-with-forks/syncing-a-fork

@mergify mergify Bot added the needs-rebase label Aug 19, 2026
@yuwenzho
yuwenzho force-pushed the cpu-fp8-w8a8-linear-moe branch from bed9c5a to bc9b6a1 Compare August 20, 2026 08:20
@mergify mergify Bot removed the needs-rebase label Aug 20, 2026
@mergify

mergify Bot commented Sep 1, 2026

Copy link
Copy Markdown
Contributor

This pull request has merge conflicts that must be resolved before it can be
merged. Please rebase the PR, @yuwenzho.

https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/working-with-forks/syncing-a-fork

@mergify mergify Bot added the needs-rebase label Sep 1, 2026
@coderabbitai

coderabbitai Bot commented Sep 7, 2026

Copy link
Copy Markdown
Contributor

Important

Draft PR not reviewed

Draft PRs are not automatically reviewed by default.

  • Trigger a manual review

To automatically review draft PRs, update your CodeRabbit configuration:

reviews:
  auto_review:
    drafts: true

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@yuwenzho
yuwenzho force-pushed the cpu-fp8-w8a8-linear-moe branch from fe3bc71 to 82421dd Compare September 8, 2026 03:32
@mergify mergify Bot removed the needs-rebase label Sep 8, 2026
@yuwenzho
yuwenzho force-pushed the cpu-fp8-w8a8-linear-moe branch from 82421dd to b1a04e1 Compare September 8, 2026 03:46
@mergify

mergify Bot commented Sep 10, 2026

Copy link
Copy Markdown
Contributor

This pull request has merge conflicts that must be resolved before it can be
merged. Please rebase the PR, @yuwenzho.

https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/working-with-forks/syncing-a-fork

@mergify mergify Bot added the needs-rebase label Sep 10, 2026
@yuwenzho
yuwenzho force-pushed the cpu-fp8-w8a8-linear-moe branch from d48d495 to 710ebc8 Compare September 14, 2026 02:15
@yuwenzho
yuwenzho marked this pull request as ready for review September 15, 2026 01:56

@claude claude Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Claude Code Review

This pull request is from a fork — automated review is disabled. A repository maintainer can comment @claude review to run a one-time review.

@bigPYJ1151 bigPYJ1151 self-assigned this Sep 15, 2026
@mergify

mergify Bot commented Sep 16, 2026

Copy link
Copy Markdown
Contributor

This pull request has merge conflicts that must be resolved before it can be
merged. Please rebase the PR, @yuwenzho.

https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/working-with-forks/syncing-a-fork

@mergify mergify Bot added the needs-rebase label Sep 16, 2026
Signed-off-by: yuwenzho <yuwen.zhou@intel.com>

@bigPYJ1151 bigPYJ1151 left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Thanks @yuwenzho Overall looks great. I just have some little tips, please check.

Comment thread cmake/cpu_extension.cmake Outdated
Comment thread vllm/model_executor/layers/fused_moe/oracle/fp8.py
Comment thread vllm/model_executor/layers/fused_moe/oracle/fp8.py
Signed-off-by: yuwenzho <yuwen.zhou@intel.com>
Signed-off-by: yuwenzho <yuwen.zhou@intel.com>
@yuwenzho
yuwenzho force-pushed the cpu-fp8-w8a8-linear-moe branch from 710ebc8 to fef9251 Compare September 18, 2026 07:43
@mergify mergify Bot removed the needs-rebase label Sep 18, 2026
@bigPYJ1151

Copy link
Copy Markdown
Member

/ci run

@github-actions

Copy link
Copy Markdown

❌ This PR is 90 commits behind upstream main. Your branch must contain every commit currently on upstream main. No new CI build was started. Merge or rebase onto the latest main, then rerun /ci run. To test this branch at your own risk, use /ci run --allow-stale.

@github-actions

Copy link
Copy Markdown

✅ Triggered Buildkite CI #89805 for commit 85d9c37f42c0.

⚠️ This PR is 90 commits behind upstream main. Running CI at your own risk because --allow-stale was requested; outdated CI configuration may cause failures. Before merging, merge or rebase onto the latest main, then rerun /ci run on the latest PR commit.

@bigPYJ1151

Copy link
Copy Markdown
Member

/ci run

@github-actions

Copy link
Copy Markdown

❌ This PR is 1 commit behind upstream main. Your branch must contain every commit currently on upstream main. No new CI build was started. Merge or rebase onto the latest main, then rerun /ci run. To test this branch at your own risk, use /ci run --allow-stale.

@bigPYJ1151

Copy link
Copy Markdown
Member

/ci run

@github-actions

Copy link
Copy Markdown

✅ Triggered Buildkite CI #89807 for commit b9d8d59146ae.

@bigPYJ1151
bigPYJ1151 merged commit b346479 into vllm-project:main Sep 18, 2026
242 of 243 checks passed
@louie-tsai

Copy link
Copy Markdown
Contributor

@louie-tsai DMR

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ci/build cpu Related to CPU backends quantization

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants