Repository navigation
[Fix] [AMD] rocprofiler-sdk: fix torch.profiler hang on TP for gfx1250-rocm1010 - #49004
Draft
yctseng0211 wants to merge 2 commits into
Draft
yctseng0211 wants to merge 2 commits into
yctseng0211 wants to merge 2 commits into
Conversation
Collaborator
Author
This branch was previously deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Motivation
On gfx1250-rocm1010, torch.profiler hangs on TP workloads. Right after profiling starts, the server stops making progress and the log keeps printing:
The bug is in rocprofiler-sdk, and ROCm 10.1 does not have the fixes.
Modifications
Rebuild ROCr and rocprofiler-sdk from the rocm-systems commit the SDK was built from, cherry-pick the commits below, and replace the SDK libraries, like the existing RCCL step.
hsa_amd_signal_wait_anywrites out of bounds, and the server crashes as soon as profiling starts:On MI450, Kimi-K2 TP8 profiling now works without any env var workaround, and the traces are complete. GSM8K accuracy (Kimi-K2, gpt-oss) and gpt-oss serving speed are the same as before.
Speed/Accuracy Tests
Kimi-K2 TP8
gpt-oss-120b TP2 (GPU 0 and 1)
MI450 (gfx1250). Stock:
rocm/sgl-dev:v0.5.23-rocm101-mi45x-20261107(stock TheRock 10.1.0 ROCr and rocprofiler-sdk). This PR:rocm/sgl-dev:v0.5.23-rocm101-mi45x-20261107_8066cd93b__test. Both images use the same TheRock 10.1.0, aiter, RCCL, Triton and torch; the stock image's sglang is 66 commits newer. gpt-oss-120b runs with--disable-custom-all-reduce(RCCL all-reduce).Serving without profiling
Random 1024 in / 512 out, 4 x concurrency prompts, mean of 2 sessions per setup.
QI=0QI=0QI=0=ROCPROFILER_QUEUE_INTERPOSITION=0.Profiling
sglang.benchmark.serving --profile, random 1024 in / 128 out, 16 prompts, concurrency 8, two profiled runs per setup.QI=0QI=0* Measured on the 20261105 image, which has the same stock ROCr and rocprofiler-sdk.
GSM8K
5-shot, 1319 questions. Measured on the 20261105 image with the same library swap (Stock vs ROCr + 8564 and rocprofiler-sdk + 9984, 12957).
On the 20261107 image with this PR: gpt-oss-120b 0.837, Kimi-K2 0.929.
Speed Tests and Profiling
as mentioned, above
Checklist
Review and Merge Process
/tag-and-rerun-ci,/tag-run-ci-label,/rerun-failed-ciCI States
Latest PR Test (Base): ✅ Run #42330198586
Latest PR Test (Extra): ❌ Run #42330198527
Latest PR Test (AMD ROCm 10): ❌ Run #42330198639
Tip
Base CI only covers the core cases, and its workload may not exercise your change. Use
/rerun-testto run the tests your change touches, or copy this prompt for an agent: