[GH-ISSUE #222] [QUESTION] Can fp8_paged_mqa_logits support next_n > 2? #127

Open
opened 2026-10-26 21:13:17 +00:00 by bsakaguchi · 4 comments
Owner

Originally created by @starwang1024 on GitHub (Oct 24, 2025).
Original GitHub issue: https://github.com/deepseek-ai/DeepGEMM/issues/222

I noticed that the code here in fp8_paged_mqa_logits only supports next_n <= 2. May I ask what the reason for this is? Additionally, what modifications would be needed to support next_n > 2?
Any reply would be very helpful.

Originally created by @starwang1024 on GitHub (Oct 24, 2025). Original GitHub issue: https://github.com/deepseek-ai/DeepGEMM/issues/222 I noticed that the [code](https://github.com/deepseek-ai/DeepGEMM/blob/main/csrc/apis/attention.hpp#L166) here in `fp8_paged_mqa_logits` only supports next_n <= 2. May I ask what the reason for this is? Additionally, what modifications would be needed to support next_n > 2? Any reply would be very helpful.
Author
Owner

@LyricZhao commented on GitHub (Dec 5, 2025):

Internally at DeepSeek, we don't use next_n > 2. But the NV https://github.com/deepseek-ai/DeepGEMM/tree/nv_dev branch supports such features.

<!-- gh-comment-id:3615934320 --> @LyricZhao commented on GitHub (Dec 5, 2025): Internally at DeepSeek, we don't use `next_n > 2`. But the NV https://github.com/deepseek-ai/DeepGEMM/tree/nv_dev branch supports such features.
Author
Owner

@Paiiiiiiiiiiiiii commented on GitHub (Dec 7, 2025):

Internally at DeepSeek, we don't use next_n > 2. But the NV https://github.com/deepseek-ai/DeepGEMM/tree/nv_dev branch supports such features.

I noticed that there is one line (DG_HOST_ASSERT(next_n == 1 or next_n == 2 or next_n == 4);), So now it still dont support nextn=3?

<!-- gh-comment-id:3621729952 --> @Paiiiiiiiiiiiiii commented on GitHub (Dec 7, 2025): > Internally at DeepSeek, we don't use `next_n > 2`. But the NV https://github.com/deepseek-ai/DeepGEMM/tree/nv_dev branch supports such features. I noticed that there is one line (DG_HOST_ASSERT(next_n == 1 or next_n == 2 or next_n == 4);), So now it still dont support nextn=3?
Author
Owner

@aiyxxj commented on GitHub (Dec 31, 2025):

Internally at DeepSeek, we don't use next_n > 2. But the NV https://github.com/deepseek-ai/DeepGEMM/tree/nv_dev branch supports such features.

I'd like to know if there are any plans to support nextn>2 on the main branch.

<!-- gh-comment-id:3701532610 --> @aiyxxj commented on GitHub (Dec 31, 2025): > Internally at DeepSeek, we don't use `next_n > 2`. But the NV https://github.com/deepseek-ai/DeepGEMM/tree/nv_dev branch supports such features. I'd like to know if there are any plans to support nextn>2 on the main branch.
Author
Owner

@hpz4311 commented on GitHub (Apr 13, 2026):

Hello, has this issue been finally resolved? I directly removed the assertion for next_n, and I found that running the test script works fine with next_n = 3, next_n = 4, and so on. Is it okay to just remove the assertion?

<!-- gh-comment-id:4234416721 --> @hpz4311 commented on GitHub (Apr 13, 2026): Hello, has this issue been finally resolved? I directly removed the assertion for next_n, and I found that running the test script works fine with next_n = 3, next_n = 4, and so on. Is it okay to just remove the assertion?
Sign in to join this conversation.
No labels
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
deepseek-ai/DeepGEMM#127
No description provided.