tile-ai / tile-ai/tilelang

[BUG] Issue 2883 CUDA regression fails on ROCm-only builds

Open Beginner friendly
#2,903 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
7.4k
Forks
745
Avg merge
1d 1h
Merged PRs (30d)
104

Description

### Problem

`testing/python/issue/test_tilelang_issue_2883.py::test_large_parallel_layout_is_injective` explicitly lowers with a CUDA target, but the test is collected on ROCm-only builds. The current main ROCm job fails before completing the suite:

```text
AttributeError: module 'tilelang.cuda._ffi_api' has no attribute 'AnnotateDeviceBoundTmaCopies'
```

The failure is visible in the gfx942 job: https://github.com/tile-ai/tilelang/actions/runs/31115687512/job/92665328476

Result: `1 failed, 1902 passed, 1236 skipped`.

### Root cause

The regression added in #2899 always constructs `tvm.target.Target("cuda")` and enters the CUDA lowering pipeline. CUDA-specific C++ registrations are absent from a ROCm-only build, so `AnnotateDeviceBoundTmaCopies` is not registered.

This is the same test-classification problem addressed in #2863, which gates CUDA-only regressions with `tilelang.testing.requires_cuda`.

### Expected behavior

The regression should continue to run on CUDA CI and skip when TileLang is built without CUDA support.

### Proposed fix

Add `@tilelang.testing.requires_cuda` to `test_large_parallel_layout_is_injective`.

### Environment

- Current main: `af475304`
- Runner: gfx942
- Workflow: Nightly ROCm 7.2, Python 3.12

Contributor guide

Open the contributing guide

Research direction

Open testing/python/issue/test_tilelang_issue_2883.py and inspect test_large_parallel_layout_is_injective, then compare its CUDA gating with the requires_cuda usage from #2863. Add the CUDA requirement and run the test in CUDA and ROCm-only environments; it should run on CUDA CI and skip without CUDA support.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
testing
Issue type
Bug
Difficulty
1/5
Estimated time
Under an hour
Activity status
Quiet
Clarity
Clearly specified
Newbie friendliness
88/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.