You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Replaces the per-test `@pytest.mark.parametrize("implementation_index", ...)`
+ runtime `if impl not in active_indices: skip` pattern with a single hook in
`conftest.pytest_generate_tests` that emits only the (device, impl) pairs
actually active on each device.
Rationale: kernel dispatch is per-device, so cross-device union (previous
`all_active_implementation_indices` helper) polluted the matrix with impls
that the selected device can't run — runtime-skipped noise. Joint generation
keeps the matrix to its semantic cell: "this device has this impl, so run it".
- `tests/conftest.py`: when both `device` and `implementation_index` are in
fixturenames, emit pairs via `op_cls.active_implementation_indices(dev)`;
fall back to a skipped placeholder (`id="skip"`) when no device has an
active impl, avoiding `[NOTSET-...]` test IDs.
- `tests/{test_add,test_gemm,test_rms_norm,test_swiglu}.py`: drop the hardcoded
`implementation_index` parametrize decorator and the runtime `active_indices`
guard — conftest now handles both.
- `tests/utils.py`: remove the `all_active_implementation_indices` helper
(superseded by per-device generation in conftest).
Same test outcome on Ascend CI (1935 passed / 1686 skipped) but the remaining
skips are now either semantically mandatory (uint dtypes unsupported by
`torch_npu`, Gemm impl=2 SFINAE-only workaround, op missing ascend impl on
op-simple pending PR #66) rather than mechanism artifacts.
0 commit comments