Commit Graph
5 Commits
Author SHA1 Message Date
andyluo7 dd9c20dbf7 [Testing] Gate CUDA-only tests so non-CUDA backends can run the suite (#2863)
A large number of tests import CUDA-only internals directly (for example
`tilelang.cuda.pipeline.CUDAPassPipelineBodyPrologue`) or exercise
NVIDIA-specific features such as TMA, LDGSTG, mbarrier, warp specialization,
tcgen05 and tfloat32. `src/cuda/CMakeLists.txt` only compiles a small
"ALWAYS" subset when `USE_CUDA=OFF`, so those FFI symbols are never
registered and the tests fail with:

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

This is not ROCm-specific -- the same tests fail on any build without the
CUDA backend, including Metal and CPU-only.

Add `@tilelang.testing.requires_cuda` to those tests, plus three
portability fixes that keep coverage on non-CUDA backends instead of
skipping it:

* `test_tilelang_transform_layout_inference.py`: CUDA emits
  `__launch_bounds__(N, 1)` while HIP emits `__launch_bounds__(N)`.
  Match both.
* `test_tilelang_transform_pipeline_planning.py`: PipelinePlanning
  deliberately strips pipeline annotations on ROCm targets other than
  gfx950 (see the guard in src/transform/pipeline_planning.cc), so assert
  the documented sequential fallback there.
* `test_tilelang_kernel_gemm.py`: the two f32f32f32 cases use `T.tfloat32`,
  which is NVIDIA-only, so narrow `requires_cuda_or_cdna` to
  `requires_cuda`.

Also refresh three stale RDNA tests: gfx12 is now a supported generation
(`get_arch` accepts 11 and 12), so they can no longer assert that gfx1200
is rejected. Force an unsupported generation instead, which is the only
way to reach the guard now that `target_is_rdna` reports only gfx11/gfx12.

Verified on 8x MI300X (gfx942, ROCm 7.2 container, torch nightly rocm7.2):
the ROCm suite goes from 105 failures to 0 with no loss of passing tests.
2026-08-04 18:22:40 +08:00
Liu Yunuo 09764cfd21 [Feature] Introduce T.tfloat32 data type support (#2032)
* [Feature] Introduce T.tfloat32

* fix: change tfloat32 type code to 130

* minor fix

* update tvm to latest

* minor fix

* minor fix

* update tvm

* add conversion from __nv_bfloat16 to tfloat32_t, update mhc example

* minor fix

* enable wgmma support for tfloat32, update gdn example

* update tf32 gemm test
2026-05-21 16:11:32 +08:00
Lei WangandZhiwen Mo f8dc61c02c test: reduce CI runtime for slow Python suites (#1932)
* test: trim CI runtime for slow Python suites

* remove useless test

* Update TVM submodule to latest commit and remove manual device assert test from CI. Replace with a call to tilelang.testing.main().

* lint fix

* fix

* revert test for eager jit

---------

Co-authored-by: Zhiwen Mo <zm125@ic.ac.uk>
2026-03-18 13:08:30 +08:00
Kuris 5358f5a272 [EagerJIT] Lazy Evaluation of Kernel Body in Eager JIT (#1690) (#1694)
* [Refactor] Support lazy evaluate in eager jit

* add test script

* fix lint error

* canonicalize signature and error of `T.empty`

* Fix comment from genai

* [EagerJIT] Add comment for eager jit stage
2026-01-23 14:33:12 +08:00
Kuris c3c8831db6 [EagerJIT] Add Support for Parameter Only Kernel Compilation (#1664)
* [Fix] Refactor type hint extraction logic in DSLMutator for better clarity and handling of annotations

* [Refactor] Remove redundant tensor creation in loop layout tests and update kernel compilation parameters
2026-01-13 16:22:49 +08:00