Skip to content

[ROCm] Unskip matmul accuracy tests for hipblas/hipblaslt - #175868

Closed
ethanwee1 wants to merge 1 commit into
pytorch:mainfrom
ethanwee1:unskip-matmul-rocm70-shapes
Closed

ethanwee1 wants to merge 1 commit into
pytorch:mainfrom
ethanwee1:unskip-matmul-rocm70-shapes

Conversation

@ethanwee1

@ethanwee1 ethanwee1 commented Feb 26, 2026 •

Copy link
Copy Markdown
Contributor

Unskipping some 64 UT's that were skipped for ROCm 7.0 due to accuracy regressions. These tests now pass with ROCm 7.2.1
cc @jeffdaily @sunway513 @jithunnair-amd @pruthvistony @ROCmSupport @jataylo @hongxiayang @naromero77amd @pragupta @jerrymannil @xinyazhang

@pytorch-bot

pytorch-bot Bot commented Feb 26, 2026 •

Copy link
Copy Markdown

🔗 Helpful Links

🧪 See artifacts and rendered test results at hud.pytorch.org/pr/175868

Note: Links to docs will display an error until the docs builds have been completed.

❌ 1 New Failure, 1 Unrelated Failure

As of commit 2d1f2a4 with merge base 7e49a76 (image):

NEW FAILURE - The following job has failed:

FLAKY - The following job failed but was likely due to flakiness present on trunk:

This comment was automatically generated by Dr. CI and updates every 15 minutes.

@pytorch-bot pytorch-bot Bot added module: rocm AMD GPU support for Pytorch topic: not user facing topic category labels Feb 26, 2026
@ethanwee1
ethanwee1 marked this pull request as draft February 26, 2026 17:08
@jithunnair-amd jithunnair-amd added ciflow/trunk Trigger trunk jobs on your pull request ciflow/rocm-mi300 Trigger "default" config CI on ROCm MI300 keep-going Don't stop on first failure, keep running tests until the end labels Feb 26, 2026
@ethanwee1
ethanwee1 marked this pull request as ready for review February 26, 2026 20:59
@jeffdaily jeffdaily added the ciflow/rocm-mi200 Trigger "default" config CI on ROCm MI200 label Feb 26, 2026
@jcaip jcaip added the triaged This issue has been looked at a team member, and triaged and prioritized into an appropriate module label Mar 4, 2026

@jeffdaily jeffdaily left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

This should be fixed in ROCm 7.2.1, but this PR doesn't conditionalize the removal of these skips.

@ethanwee1
ethanwee1 force-pushed the unskip-matmul-rocm70-shapes branch from 901775d to a00853c Compare March 17, 2026 19:00
@pytorch-bot pytorch-bot Bot removed ciflow/trunk Trigger trunk jobs on your pull request ciflow/rocm-mi300 Trigger "default" config CI on ROCm MI300 ciflow/rocm-mi200 Trigger "default" config CI on ROCm MI200 labels Mar 17, 2026
@jithunnair-amd jithunnair-amd added ciflow/trunk Trigger trunk jobs on your pull request ciflow/rocm-mi300 Trigger "default" config CI on ROCm MI300 ciflow/rocm-mi200 Trigger "default" config CI on ROCm MI200 labels Mar 17, 2026
@pytorch-bot

pytorch-bot Bot commented Mar 17, 2026

Copy link
Copy Markdown

To add the ciflow label ciflow/rocm-mi300 please first approve the workflows that are awaiting approval (scroll to the bottom of this page).

This helps ensure we don't trigger CI on this PR until it is actually authorized to do so. Please ping one of the reviewers if you do not have access to approve and run workflows.

@pytorch-bot

pytorch-bot Bot commented Mar 17, 2026

Copy link
Copy Markdown

To add the ciflow label ciflow/rocm-mi200 please first approve the workflows that are awaiting approval (scroll to the bottom of this page).

This helps ensure we don't trigger CI on this PR until it is actually authorized to do so. Please ping one of the reviewers if you do not have access to approve and run workflows.

@pytorch-bot

pytorch-bot Bot commented Mar 17, 2026

Copy link
Copy Markdown

To add the ciflow label ciflow/trunk please first approve the workflows that are awaiting approval (scroll to the bottom of this page).

This helps ensure we don't trigger CI on this PR until it is actually authorized to do so. Please ping one of the reviewers if you do not have access to approve and run workflows.

@pytorch-bot pytorch-bot Bot removed ciflow/rocm-mi300 Trigger "default" config CI on ROCm MI300 ciflow/rocm-mi200 Trigger "default" config CI on ROCm MI200 ciflow/trunk Trigger trunk jobs on your pull request labels Mar 17, 2026
@ethanwee1

Copy link
Copy Markdown
Contributor Author

@pytorchbot rebase

@pytorchmergebot

Copy link
Copy Markdown
Collaborator

@pytorchbot started a rebase job onto refs/remotes/origin/viable/strict. Check the current status here

@pytorchmergebot

Copy link
Copy Markdown
Collaborator

Rebase failed due to Command git -C /home/runner/work/pytorch/pytorch rebase refs/remotes/origin/viable/strict pull/175868/head returned non-zero exit code 1

Rebasing (1/1)
Auto-merging test/test_matmul_cuda.py
CONFLICT (content): Merge conflict in test/test_matmul_cuda.py
error: could not apply a00853c0221... [ROCm] Unskip matmul accuracy tests for hipblas/hipblaslt
hint: Resolve all conflicts manually, mark them as resolved with
hint: "git add/rm <conflicted_files>", then run "git rebase --continue".
hint: You can instead skip this commit: run "git rebase --skip".
hint: To abort and get back to the state before "git rebase", run "git rebase --abort".
hint: Disable this message with "git config set advice.mergeConflict false"
Could not apply a00853c0221... # [ROCm] Unskip matmul accuracy tests for hipblas/hipblaslt

Raised by https://github.com/pytorch/pytorch/actions/runs/23211882786

@pytorchmergebot

Copy link
Copy Markdown
Collaborator

@pytorchbot started a rebase job onto refs/remotes/origin/viable/strict. Check the current status here

Conditionalize skip conditions for test_mm_bmm_dtype_overload and
test_addmm_baddmm_dtype_overload on ROCm version < 7.2.1, rather than
unconditionally removing them. These tests had accuracy regressions in
hipblas and hipblaslt in ROCm 7.0 for certain shapes, which are fixed
in ROCm 7.2.1.
@pytorchmergebot

Copy link
Copy Markdown
Collaborator

Successfully rebased unskip-matmul-rocm70-shapes onto refs/remotes/origin/viable/strict, please pull locally before adding more changes (for example, via git checkout unskip-matmul-rocm70-shapes && git pull --rebase)

@pytorch-bot

pytorch-bot Bot commented May 1, 2026 •

Copy link
Copy Markdown

Workflows were awaiting approval. CI has now been triggered for the ciflow labels on this PR.

@pytorch-bot

pytorch-bot Bot commented May 1, 2026

Copy link
Copy Markdown

The following ciflow label(s) have been added but CI has not been triggered yet because the workflows are awaiting approval:

  • ciflow/trunk
  • ciflow/rocm-mi300
  • ciflow/h100
  • ciflow/b200

Once a maintainer approves the workflows (scroll to the bottom of the PR page), the corresponding CI jobs will be triggered automatically. Please ping one of the reviewers if you do not have access to approve and run workflows.

@jeffdaily

Copy link
Copy Markdown
Collaborator

@pytorchbot merge

@pytorchmergebot

Copy link
Copy Markdown
Collaborator

Merge started

Your 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

Advanced Debugging
Check the merge workflow status
here

@pytorchmergebot

Copy link
Copy Markdown
Collaborator

Merge failed

Reason: 1 jobs have failed, first few of them are: rocm-mi300 / linux-noble-rocm-py3.12-mi300 / test (default, 4, 6, linux.rocm.gpu.gfx942.1)

Details for Dev Infra team Raised by workflow job

@jeffdaily

Copy link
Copy Markdown
Collaborator

@pytorchbot merge -f "unrelated failures"

@pytorchmergebot

Copy link
Copy Markdown
Collaborator

Merge started

Your change will be merged immediately since you used the force (-f) flag, bypassing any CI checks (ETA: 1-5 minutes). Please use -f as last resort and instead consider -i/--ignore-current to continue the merge ignoring current failures. This will allow currently pending tests to finish and report signal before the merge.

Learn more about merging in the wiki.

Questions? Feedback? Please reach out to the PyTorch DevX Team

Advanced Debugging
Check the merge workflow status
here

Alokksinha00 pushed a commit to Alokksinha00/pytorch that referenced this pull request May 15, 2026
…5868)

Unskipping some 64 UT's that were skipped for ROCm 7.0 due to accuracy regressions. These tests now pass with ROCm 7.2.1

Pull Request resolved: pytorch#175868
Approved by: https://github.com/jeffdaily
pytorchmergebot pushed a commit that referenced this pull request Jun 4, 2026
…186098)

## Summary
Extend the hipBLAS/hipBLASLt accuracy `SkipTest` gate in `test_mm_bmm_dtype_overload` and `test_addmm_baddmm_dtype_overload` so MI200 (gfx90a) also skips the known-bad bf16/fp16 shape cases, not only ROCm versions before 7.2.1. MI210 on HIP 7.2.x still fails bf16 N=1 GEMM accuracy after PR #175868 narrowed the skip to `_get_torch_rocm_version() < (7, 2, 1)`.

## Test plan
Validated on MI200 (gfx90a / MI210) in `linux-jammy-rocm-py3.10-mi200 / test (default, …, linux.rocm.gpu.mi210.1)`:
- Run: https://github.com/pytorch/pytorch/actions/runs/26899002259
- Job (shard 1/6, where `test_matmul_cuda` runs): https://github.com/pytorch/pytorch/actions/runs/26899002259/job/79352276629

Results:
- The targeted `test_mm_bmm_dtype_overload*` and `test_addmm_baddmm_dtype_overload*` accuracy cases are now **SKIPPED** on MI200 (previously failing), with skip message `accuracy regression in hipblas and hipblaslt in ROCm 7.0 for certain shapes`.
- `test_matmul_cuda`: 1594 collected, **0 failures / 0 errors**; **92 targeted dtype-overload cases skipped**.
- The skip is scoped to the intended bad shapes only (0 out-of-scope skips, 0 missed matching cases); CUDA and non-MI200 ROCm arches are unaffected.
- The remaining red ROCm shards are unrelated pre-existing failures, not caused by this PR: `inductor/test_torchinductor_opinfo.py::TestInductorOpInfoCUDA::test_comprehensive_addmm_cuda_float16`, `inductor/test_fused_attention.py::SDPAPatternRewriterGpuTests::test_sdpa_rewriter_1_gpu`, and `inductor/test_flex_attention.py::TestLearnableBiasesCUDA::test_comparison_vs_sdpa_with_learnable_bias_cuda`.

### Evidence (XML test report)
The per-test SKIPPED verdict is recorded in the XML test report; the console log only shows the file-level `test_matmul_cuda 1/1 was successful`.

XML artifact (run 26899002259 / shard 1 job 79352276629):
- `https://gha-artifacts.s3.amazonaws.com/pytorch/pytorch/26899002259/1/artifact/test-reports-test-default-1-6-linux.rocm.gpu.mi210.1_79352276629.zip`
- inner path: `test-reports/python-pytest/test_matmul_cuda/test_matmul_cuda-edec47fe7df60a0f.xml`

Verbatim skip elements:
```xml
<testcase classname="TestMatmulCudaCUDA" name="test_mm_bmm_dtype_overload_bfloat16_M_1_N_1_K_32_batch_size_1_backend_cublas_cuda" time="0.002" file="test_matmul_cuda.py"><skipped type="pytest.skip" message="accuracy regression in hipblas and hipblaslt in ROCm 7.0 for certain shapes">/var/lib/jenkins/workspace/test/test_matmul_cuda.py:892: accuracy regression in hipblas and hipblaslt in ROCm 7.0 for certain shapes</skipped></testcase>
```
```xml
<testcase classname="TestMatmulCudaCUDA" name="test_addmm_baddmm_dtype_overload_bfloat16_M_1_N_1_K_32_batch_size_1_broadcast_self_False_high_precision_self_False_backend_cublaslt_cuda" time="0.002" file="test_matmul_cuda.py"><skipped type="pytest.skip" message="accuracy regression in hipblas and hipblaslt in ROCm 7.0 for certain shapes">/var/lib/jenkins/workspace/test/test_matmul_cuda.py:959: accuracy regression in hipblas and hipblaslt in ROCm 7.0 for certain shapes</skipped></testcase>
```

Made with Cursor

Pull Request resolved: #186098
Approved by: https://github.com/jeffdaily
aperson30 pushed a commit to aperson30/pytorch that referenced this pull request Jun 20, 2026
…5868)

Unskipping some 64 UT's that were skipped for ROCm 7.0 due to accuracy regressions. These tests now pass with ROCm 7.2.1

Pull Request resolved: pytorch#175868
Approved by: https://github.com/jeffdaily
gplutop7 pushed a commit to gplutop7/pytorch that referenced this pull request Jul 15, 2026
…5868)

Unskipping some 64 UT's that were skipped for ROCm 7.0 due to accuracy regressions. These tests now pass with ROCm 7.2.1

Pull Request resolved: pytorch#175868
Approved by: https://github.com/jeffdaily
gplutop7 pushed a commit to gplutop7/pytorch that referenced this pull request Jul 15, 2026
…ytorch#186098)

## Summary
Extend the hipBLAS/hipBLASLt accuracy `SkipTest` gate in `test_mm_bmm_dtype_overload` and `test_addmm_baddmm_dtype_overload` so MI200 (gfx90a) also skips the known-bad bf16/fp16 shape cases, not only ROCm versions before 7.2.1. MI210 on HIP 7.2.x still fails bf16 N=1 GEMM accuracy after PR pytorch#175868 narrowed the skip to `_get_torch_rocm_version() < (7, 2, 1)`.

## Test plan
Validated on MI200 (gfx90a / MI210) in `linux-jammy-rocm-py3.10-mi200 / test (default, …, linux.rocm.gpu.mi210.1)`:
- Run: https://github.com/pytorch/pytorch/actions/runs/26899002259
- Job (shard 1/6, where `test_matmul_cuda` runs): https://github.com/pytorch/pytorch/actions/runs/26899002259/job/79352276629

Results:
- The targeted `test_mm_bmm_dtype_overload*` and `test_addmm_baddmm_dtype_overload*` accuracy cases are now **SKIPPED** on MI200 (previously failing), with skip message `accuracy regression in hipblas and hipblaslt in ROCm 7.0 for certain shapes`.
- `test_matmul_cuda`: 1594 collected, **0 failures / 0 errors**; **92 targeted dtype-overload cases skipped**.
- The skip is scoped to the intended bad shapes only (0 out-of-scope skips, 0 missed matching cases); CUDA and non-MI200 ROCm arches are unaffected.
- The remaining red ROCm shards are unrelated pre-existing failures, not caused by this PR: `inductor/test_torchinductor_opinfo.py::TestInductorOpInfoCUDA::test_comprehensive_addmm_cuda_float16`, `inductor/test_fused_attention.py::SDPAPatternRewriterGpuTests::test_sdpa_rewriter_1_gpu`, and `inductor/test_flex_attention.py::TestLearnableBiasesCUDA::test_comparison_vs_sdpa_with_learnable_bias_cuda`.

### Evidence (XML test report)
The per-test SKIPPED verdict is recorded in the XML test report; the console log only shows the file-level `test_matmul_cuda 1/1 was successful`.

XML artifact (run 26899002259 / shard 1 job 79352276629):
- `https://gha-artifacts.s3.amazonaws.com/pytorch/pytorch/26899002259/1/artifact/test-reports-test-default-1-6-linux.rocm.gpu.mi210.1_79352276629.zip`
- inner path: `test-reports/python-pytest/test_matmul_cuda/test_matmul_cuda-edec47fe7df60a0f.xml`

Verbatim skip elements:
```xml
<testcase classname="TestMatmulCudaCUDA" name="test_mm_bmm_dtype_overload_bfloat16_M_1_N_1_K_32_batch_size_1_backend_cublas_cuda" time="0.002" file="test_matmul_cuda.py"><skipped type="pytest.skip" message="accuracy regression in hipblas and hipblaslt in ROCm 7.0 for certain shapes">/var/lib/jenkins/workspace/test/test_matmul_cuda.py:892: accuracy regression in hipblas and hipblaslt in ROCm 7.0 for certain shapes</skipped></testcase>
```
```xml
<testcase classname="TestMatmulCudaCUDA" name="test_addmm_baddmm_dtype_overload_bfloat16_M_1_N_1_K_32_batch_size_1_broadcast_self_False_high_precision_self_False_backend_cublaslt_cuda" time="0.002" file="test_matmul_cuda.py"><skipped type="pytest.skip" message="accuracy regression in hipblas and hipblaslt in ROCm 7.0 for certain shapes">/var/lib/jenkins/workspace/test/test_matmul_cuda.py:959: accuracy regression in hipblas and hipblaslt in ROCm 7.0 for certain shapes</skipped></testcase>
```

Made with Cursor

Pull Request resolved: pytorch#186098
Approved by: https://github.com/jeffdaily
aws-kingrj pushed a commit to amazon-contributing/upstream-to-pytorch that referenced this pull request Jul 29, 2026
…5868)

Unskipping some 64 UT's that were skipped for ROCm 7.0 due to accuracy regressions. These tests now pass with ROCm 7.2.1

Pull Request resolved: pytorch#175868
Approved by: https://github.com/jeffdaily
aws-kingrj pushed a commit to amazon-contributing/upstream-to-pytorch that referenced this pull request Jul 29, 2026
…ytorch#186098)

## Summary
Extend the hipBLAS/hipBLASLt accuracy `SkipTest` gate in `test_mm_bmm_dtype_overload` and `test_addmm_baddmm_dtype_overload` so MI200 (gfx90a) also skips the known-bad bf16/fp16 shape cases, not only ROCm versions before 7.2.1. MI210 on HIP 7.2.x still fails bf16 N=1 GEMM accuracy after PR pytorch#175868 narrowed the skip to `_get_torch_rocm_version() < (7, 2, 1)`.

## Test plan
Validated on MI200 (gfx90a / MI210) in `linux-jammy-rocm-py3.10-mi200 / test (default, …, linux.rocm.gpu.mi210.1)`:
- Run: https://github.com/pytorch/pytorch/actions/runs/26899002259
- Job (shard 1/6, where `test_matmul_cuda` runs): https://github.com/pytorch/pytorch/actions/runs/26899002259/job/79352276629

Results:
- The targeted `test_mm_bmm_dtype_overload*` and `test_addmm_baddmm_dtype_overload*` accuracy cases are now **SKIPPED** on MI200 (previously failing), with skip message `accuracy regression in hipblas and hipblaslt in ROCm 7.0 for certain shapes`.
- `test_matmul_cuda`: 1594 collected, **0 failures / 0 errors**; **92 targeted dtype-overload cases skipped**.
- The skip is scoped to the intended bad shapes only (0 out-of-scope skips, 0 missed matching cases); CUDA and non-MI200 ROCm arches are unaffected.
- The remaining red ROCm shards are unrelated pre-existing failures, not caused by this PR: `inductor/test_torchinductor_opinfo.py::TestInductorOpInfoCUDA::test_comprehensive_addmm_cuda_float16`, `inductor/test_fused_attention.py::SDPAPatternRewriterGpuTests::test_sdpa_rewriter_1_gpu`, and `inductor/test_flex_attention.py::TestLearnableBiasesCUDA::test_comparison_vs_sdpa_with_learnable_bias_cuda`.

### Evidence (XML test report)
The per-test SKIPPED verdict is recorded in the XML test report; the console log only shows the file-level `test_matmul_cuda 1/1 was successful`.

XML artifact (run 26899002259 / shard 1 job 79352276629):
- `https://gha-artifacts.s3.amazonaws.com/pytorch/pytorch/26899002259/1/artifact/test-reports-test-default-1-6-linux.rocm.gpu.mi210.1_79352276629.zip`
- inner path: `test-reports/python-pytest/test_matmul_cuda/test_matmul_cuda-edec47fe7df60a0f.xml`

Verbatim skip elements:
```xml
<testcase classname="TestMatmulCudaCUDA" name="test_mm_bmm_dtype_overload_bfloat16_M_1_N_1_K_32_batch_size_1_backend_cublas_cuda" time="0.002" file="test_matmul_cuda.py"><skipped type="pytest.skip" message="accuracy regression in hipblas and hipblaslt in ROCm 7.0 for certain shapes">/var/lib/jenkins/workspace/test/test_matmul_cuda.py:892: accuracy regression in hipblas and hipblaslt in ROCm 7.0 for certain shapes</skipped></testcase>
```
```xml
<testcase classname="TestMatmulCudaCUDA" name="test_addmm_baddmm_dtype_overload_bfloat16_M_1_N_1_K_32_batch_size_1_broadcast_self_False_high_precision_self_False_backend_cublaslt_cuda" time="0.002" file="test_matmul_cuda.py"><skipped type="pytest.skip" message="accuracy regression in hipblas and hipblaslt in ROCm 7.0 for certain shapes">/var/lib/jenkins/workspace/test/test_matmul_cuda.py:959: accuracy regression in hipblas and hipblaslt in ROCm 7.0 for certain shapes</skipped></testcase>
```

Made with Cursor

Pull Request resolved: pytorch#186098
Approved by: https://github.com/jeffdaily
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ciflow/rocm-mi300 Trigger "default" config CI on ROCm MI300 ciflow/trunk Trigger trunk jobs on your pull request keep-going Don't stop on first failure, keep running tests until the end Merged module: rocm AMD GPU support for Pytorch open source topic: not user facing topic category triaged This issue has been looked at a team member, and triaged and prioritized into an appropriate module

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants