Skip to content

[tensilelite] Fix test_PlaceholderMerge xfail for TheRock CI - #7716

Merged
archana-ramalingam merged 2 commits into
developfrom
users/aramalin/tensilelite-therock-ci-2
May 26, 2026
Merged

archana-ramalingam merged 2 commits into
developfrom
users/aramalin/tensilelite-therock-ci-2

Conversation

@archana-ramalingam

@archana-ramalingam archana-ramalingam commented May 23, 2026 •

Copy link
Copy Markdown
Contributor

Summary

For test_PlaceholderMerge.py:

  • In math-ci, the logic files are available, so all tests pass as expected because the xfail condition depends on the presence of those files.
  • In TheRock CI, a sparse checkout omits these files, so the xfail condition is triggered for all tests.
    However, 3 of the 5 tests do not rely on the logic files, resulting in unexpected passes (xpass), which in turn cause CI failures.

Technical details

The module-level pytestmark = pytest.mark.xfail(not _LOGIC_ROOT.is_dir(), ...) applied to ALL 5 tests in the module.
However, 3 / 5 tests don't need logic files and pass regardless — causing XPASS(strict) failures in TheRock CI (unexpected pass treated as failure by xfail_strict=True in pytest.ini).

Fix

  • Define a reusable _needs_logic_dir xfail marker to verify if logic files exist.
  • Apply @_needs_logic_dir only to the 2 tests that need logic files.
  • The other 3 tests run and pass normally without any logic file related markers.

Test plan

  • TheRock CI passes (no XPASS failures)
  • Source-tree tests still pass (pytest Tensile/Tests/unit/test_PlaceholderMerge.py -v)

Ref: #7481

AIGECORE-1997

…nments

Move xfail marker from module-level pytestmark to per-test decorators
so only tests that actually need logic YAML files are marked xfail.

The module-level pytestmark caused XPASS(strict) failures in TheRock CI
where logic files are absent but tests that don't need them still pass.

Co-Authored-By: Claude Opus 4 (1M context) <noreply@anthropic.com>
@archana-ramalingam
archana-ramalingam requested a review from a team as a code owner May 23, 2026 00:15
@archana-ramalingam archana-ramalingam changed the title [tensilelite] Fix test_PlaceholderMerge xfail for install-tree environments [tensilelite] Fix test_PlaceholderMerge xfail for TheRock CI May 23, 2026

@talumbau talumbau 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.

For clarity - my understanding is as follows:

In some cases, we run these Placeholder merge tests in an environment where the logic files directories exist, in some cases we have a test environment where they do not exist. We want to xfail them since in rocm-libraries standard CI, the directories do not exist. However, in TheRock artifacts, they do exist, Xfailed test -> Passes == CI failure with XPASS(strict). Thus this PR conditionally sets the xfail. Thanks @archana-ramalingam

@codecov-commenter

codecov-commenter commented May 26, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.

❌ Your project status has failed because the head coverage (77.83%) is below the target coverage (80.00%). You can increase the head coverage or adjust the target coverage.

Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #7716      +/-   ##
===========================================
- Coverage    61.95%   61.87%   -0.08%     
===========================================
  Files         2086     2086              
  Lines       357056   357253     +197     
  Branches     53784    53858      +74     
===========================================
- Hits        221180   221024     -156     
- Misses      117067   117426     +359     
+ Partials     18809    18803       -6     
Flag Coverage Δ *Carryforward flag
TensileLite 26.06% <ø> (-0.39%) ⬇️
hipBLAS 90.65% <ø> (ø) Carriedforward from 6824cec
hipBLASLt 41.27% <ø> (ø)
hipCUB 82.68% <ø> (ø) Carriedforward from 6824cec
hipDNN 85.87% <ø> (ø) Carriedforward from 6824cec
hipFFT 50.00% <ø> (ø) Carriedforward from 6824cec
hipRAND 76.12% <ø> (ø) Carriedforward from 6824cec
hipSOLVER 69.24% <ø> (ø) Carriedforward from 6824cec
hipSPARSE 85.09% <ø> (ø) Carriedforward from 6824cec
rocBLAS 48.11% <ø> (ø) Carriedforward from 6824cec
rocFFT 52.07% <ø> (ø) Carriedforward from 6824cec
rocRAND 57.04% <ø> (ø) Carriedforward from 6824cec
rocSOLVER 77.83% <ø> (ø) Carriedforward from 6824cec
rocSPARSE 72.68% <ø> (ø) Carriedforward from 6824cec

*This pull request uses carry forward flags. Click here to find out more.
see 9 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@archana-ramalingam
archana-ramalingam merged commit f96e909 into develop May 26, 2026
80 of 82 checks passed
@archana-ramalingam
archana-ramalingam deleted the users/aramalin/tensilelite-therock-ci-2 branch May 26, 2026 20:54
talumbau pushed a commit that referenced this pull request Jun 10, 2026
## Summary
Add `tensilelite` to the blas `projects_to_test` list in
`therock_matrix.py` so tensilelite/rocisa tests run in TheRock CI.

## Technical details
- Enable the `TensileLite` component in `therock_matrix.py`.
- Guarded `from hip import hip` with try/except in `gpu_test_helpers.py`
to prevent `ImportError` on systems without hip. Added `requires_gpu`
marker combining hip availability + gfx950 architecture check, applied
to all GPU unit test classes. (only subtile unit tests require gfx950
and `hip`)

### Dependency
- #6205: Added `CMake` install rules to package `TensileLite`'s Python
packages (Tensilelite + rocisa) for artifact-based testing in `TheRock`
CI.
- #7716: Narrowed xfail marker in `test_PlaceholderMerge.py` to only 2
tests that fail in absence of the logic files
- ROCm/TheRock#5529: Added the `tensilelite`
test component configuration.
- #8196: Update `TheRock`
reference to include ROCm/TheRock#5529 changes

## Test plan
- [x] `TheRock` CI blas test job picks up `tensilelite` and runs
tensilelite/rocisa tests
- [x] GPU unit tests skip cleanly (not error) when `hip` module is not
installed

## Test results
- [x] Artifact layout verified —
`share/hipblaslt/tensilelite/{Tensile,rocisa,rocisa_tests}/`
- [x] Smoke import: `Tensile.ROOT_PATH` and `rocisa.__file__` resolve to
artifact paths
- [x]
[rocisa](https://github.com/ROCm/rocm-libraries/actions/runs/27043375484/job/79836587812?pr=7872#step:11:92):
48 passed
- [x] TensileLite [unit
tests](https://github.com/ROCm/rocm-libraries/actions/runs/27043375484/job/79836587812?pr=7872#step:11:1569):
   - 1325 passed
- 212 skipped (subtile tests requires [gfx950
runners](ROCm/TheRock#3288))
- 1 xfailed ([Issue](#7481)
filed)

AIGECORE-1997

---------

Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
Co-authored-by: therockbot <therockbot@amd.com>
cderb pushed a commit that referenced this pull request Jun 12, 2026
## Summary
Add `tensilelite` to the blas `projects_to_test` list in
`therock_matrix.py` so tensilelite/rocisa tests run in TheRock CI.

## Technical details
- Enable the `TensileLite` component in `therock_matrix.py`.
- Guarded `from hip import hip` with try/except in `gpu_test_helpers.py`
to prevent `ImportError` on systems without hip. Added `requires_gpu`
marker combining hip availability + gfx950 architecture check, applied
to all GPU unit test classes. (only subtile unit tests require gfx950
and `hip`)

### Dependency
- #6205: Added `CMake` install rules to package `TensileLite`'s Python
packages (Tensilelite + rocisa) for artifact-based testing in `TheRock`
CI.
- #7716: Narrowed xfail marker in `test_PlaceholderMerge.py` to only 2
tests that fail in absence of the logic files
- ROCm/TheRock#5529: Added the `tensilelite`
test component configuration.
- #8196: Update `TheRock`
reference to include ROCm/TheRock#5529 changes

## Test plan
- [x] `TheRock` CI blas test job picks up `tensilelite` and runs
tensilelite/rocisa tests
- [x] GPU unit tests skip cleanly (not error) when `hip` module is not
installed

## Test results
- [x] Artifact layout verified —
`share/hipblaslt/tensilelite/{Tensile,rocisa,rocisa_tests}/`
- [x] Smoke import: `Tensile.ROOT_PATH` and `rocisa.__file__` resolve to
artifact paths
- [x]
[rocisa](https://github.com/ROCm/rocm-libraries/actions/runs/27043375484/job/79836587812?pr=7872#step:11:92):
48 passed
- [x] TensileLite [unit
tests](https://github.com/ROCm/rocm-libraries/actions/runs/27043375484/job/79836587812?pr=7872#step:11:1569):
   - 1325 passed
- 212 skipped (subtile tests requires [gfx950
runners](ROCm/TheRock#3288))
- 1 xfailed ([Issue](#7481)
filed)

AIGECORE-1997

---------

Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
Co-authored-by: therockbot <therockbot@amd.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants