Repository navigation
[ROCm] Unskip Python chrome-trace export tests except the envelope check - #197136
pablo-garay wants to merge 1 commit into
Conversation
The class-level skipIf(TEST_WITH_ROCM) on TestPythonChromeTraceExport was added with the class in pytorch#194854 on the reasoning that the exporter's envelope is NVIDIA-shaped. Only one of the five tests checks the envelope. The other three compare the Python streaming exporter's event stream against kineto's C++ save() (plus the gzip and plain-JSON variants) and pass on ROCm: the exporter already degrades cleanly there (cuda-bindings is nulled on ROCm in torch/cuda/_utils.py, sharedMemPerBlockOptin is guarded). The fifth self-skips on ROCm because CUDA graph annotations are unavailable. This moves the skip to test_python_export_envelope_matches_kineto and records the concrete disagreement: kineto's ROCm backend writes hip_driver_version/hip_runtime_version instead of the cuda_* keys, and its device-property set names two fields differently (maxSharedMemoryPerMultiProcessor, regsPerBlock) from the cudaDeviceProp shape the exporter reproduces. Defining ROCm equivalence for the envelope needs an exporter change and a kineto change and is out of scope here. Test Plan: On gfx950 (MI355X, ROCm 10.0), with the class gate removed: ``` python -m pytest test/profiler/test_profiler.py -k "TestPythonChromeTraceExport and (gzip or plain_json or export_matches_kineto)" --flake-finder --flake-runs=25 python test/profiler/test_profiler.py -k TestPythonChromeTraceExport python test/profiler/test_profiler.py ``` 75/75 flake-finder passes and 25/25 per test in isolated processes. Full class: 3 pass, 1 skip (annotations unavailable on ROCm), and the envelope test fails as expected without its skip. Full file otherwise unchanged (one pre-existing, unrelated TestMetadataJsonFormat error on the local build). Authored with an AI assistant (Claude Code); the diff was reviewed by the human author.
🔗 Helpful Links🧪 See artifacts and rendered test results at hud.pytorch.org/pr/197136
Note: Links to docs will display an error until the docs builds have been completed. ❌ 2 New Failures, 1 PendingAs of commit 0c6dc86 with merge base c00221a ( NEW FAILURES - The following jobs have failed:
This comment was automatically generated by Dr. CI and updates every 15 minutes. |
|
@pytorchbot merge |
Merge startedYour change will be merged once all checks pass (ETA 0-4 Hours). Learn more about merging in the wiki. Questions? Feedback? Please reach out to the PyTorch DevX Team |
Merge failedReason: 1 jobs have failed, first few of them are: trunk / linux-noble-rocm-py3.11-mi350 / test (distributed, 1, 3, amd-dpx-linux.rocm.gpu.gfx950.2) Details for Dev Infra teamRaised by workflow job |
|
@pytorchbot merge -i |
Merge startedYour change will be merged while ignoring the following 2 checks: trunk / linux-noble-rocm-py3.11-mi350 / test (distributed, 2, 3, amd-dpx-linux.rocm.gpu.gfx950.2), trunk / linux-noble-rocm-py3.11-mi350 / test (distributed, 1, 3, amd-dpx-linux.rocm.gpu.gfx950.2) Learn more about merging in the wiki. Questions? Feedback? Please reach out to the PyTorch DevX Team |
The class-level
skipIf(TEST_WITH_ROCM)onTestPythonChromeTraceExportwas added with the class in #194854 on the reasoning that the exporter's envelope is NVIDIA-shaped. Only one of the five tests checks the envelope. The other three compare the Python streaming exporter's event stream against kineto's C++save()(plus the gzip and plain-JSON variants) and pass on ROCm: the exporter already degrades cleanly there (cuda-bindings is nulled on ROCm intorch/cuda/_utils.py,sharedMemPerBlockOptinis guarded). The fifth self-skips on ROCm because CUDA graph annotations are unavailable.This moves the skip to
test_python_export_envelope_matches_kinetoand records the concrete disagreement: kineto's ROCm backend writeship_driver_version/hip_runtime_versioninstead of thecuda_*keys, and its device-property set names two fields differently (maxSharedMemoryPerMultiProcessor,regsPerBlock) from thecudaDevicePropshape the exporter reproduces. Defining ROCm equivalence for the envelope needs an exporter change and a kineto change and is out of scope here.Test plan, on gfx950 (ROCm 10.0, HIP 7.15) with the class gate removed locally: 75/75 flake-finder passes and 25/25 per test in isolated processes for the three unskipped tests; full class 3 pass + 1 skip + the envelope test failing as expected without its skip; the rest of test_profiler.py unchanged.
gfx942/gfx90a validation via the ciflow labels below; test_profiler is not in the navi31 include list, so gfx1100 gets no CI either way (the three tests exercise only the Python exporter against kineto's own output, no arch-specific path).
This PR was authored with the assistance of an AI agent (Claude). The analysis and test results were verified by hand.
cc @jeffdaily @sunway513 @jithunnair-amd @pruthvistony @ROCmSupport @jataylo @hongxiayang @naromero77amd @pragupta @jerrymannil @xinyazhang