[PR #1240] [CLOSED] Avoid unused MTP branch stream on HIP #3329

Closed
opened 2026-11-07 14:40:42 +07:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/Niko1221/Strata/pull/1240
Author: @rkcth
Created: 10/6/2026
Status: ❌ Closed

Base: main ← Head: fix/hip-mtp-unused-branch-stream


📝 Commits (1)

  • 7e32fd3 Avoid unused MTP branch stream on HIP

📊 Changes

1 file changed (+3 additions, -0 deletions)

View changed files

📝 src/core/mtp.cpp (+3 -0)

📄 Description

On HIP, fresh long prompts with MTP can lose prompt-processing speed after the first request. MtpDrafter::load creates a branch stream and two events even though the shared-expert branch is disabled on HIP. Guard those unused resources for CUDA, leaving the CUDA branch path unchanged.

On a Radeon AI PRO R9700 with IQ3_S, v0.1.40.1 processed a fresh ~30K-token prompt at 1,161 tok/s, then the next at 842 tok/s. With this fix, five successive fresh ~30K/~33K prompts measured 1,155, 1,188, 1,190, 1,142, and 1,139 tok/s. All generated the requested 301–305 output tokens. Two concurrent 2K/128-token requests also completed, and the HIP build passed.

The regression bisects to 4a5713f, which introduced the branch resource allocation. The experiment guarded the stream and events together; it did not isolate which allocation causes the HIP runtime effect. NVIDIA hardware has not been tested with this patch.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/Niko1221/Strata/pull/1240 **Author:** [@rkcth](https://github.com/rkcth) **Created:** 10/6/2026 **Status:** ❌ Closed **Base:** `main` ← **Head:** `fix/hip-mtp-unused-branch-stream` --- ### 📝 Commits (1) - [`7e32fd3`](https://github.com/Niko1221/Strata/commit/7e32fd3e2db1daa1e92e2ad626c80e546e6611f4) Avoid unused MTP branch stream on HIP ### 📊 Changes **1 file changed** (+3 additions, -0 deletions) <details> <summary>View changed files</summary> 📝 `src/core/mtp.cpp` (+3 -0) </details> ### 📄 Description On HIP, fresh long prompts with MTP can lose prompt-processing speed after the first request. `MtpDrafter::load` creates a branch stream and two events even though the shared-expert branch is disabled on HIP. Guard those unused resources for CUDA, leaving the CUDA branch path unchanged. On a Radeon AI PRO R9700 with IQ3_S, v0.1.40.1 processed a fresh ~30K-token prompt at 1,161 tok/s, then the next at 842 tok/s. With this fix, five successive fresh ~30K/~33K prompts measured 1,155, 1,188, 1,190, 1,142, and 1,139 tok/s. All generated the requested 301–305 output tokens. Two concurrent 2K/128-token requests also completed, and the HIP build passed. The regression bisects to `4a5713f`, which introduced the branch resource allocation. The experiment guarded the stream and events together; it did not isolate which allocation causes the HIP runtime effect. NVIDIA hardware has not been tested with this patch. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-11-07 14:40:42 +07:00
Sign in to join this conversation.
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
Niko1221/Strata#3329
No description provided.