Metadata-Version: 2.4
Name: tirx-harness
Version: 0.1.0rc0
Summary: Installable inspection and simulation tools for TIRx kernels
Project-URL: Homepage, https://tirxharness.mlc.ai
Project-URL: Repository, https://github.com/mlc-ai/TIRx-harness
Requires-Python: <3.14,>=3.12
Description-Content-Type: text/markdown
Requires-Dist: apache-tvm==0.27.0
Requires-Dist: apache-tvm-ffi==0.1.14.post0
Requires-Dist: numpy>=1.24
Requires-Dist: threadpoolctl<4,>=3.6
Provides-Extra: test
Requires-Dist: pytest>=8; extra == "test"
Requires-Dist: pytest-xdist>=3; extra == "test"
Requires-Dist: ml-dtypes; extra == "test"

# tirx-harness

Inspection, numerical simulation, and native correctness checks for TIRx kernels.

```bash
python -m pip install tirx-harness==0.1.0rc0
```

The release supports Python 3.12 and 3.13 on Linux x86_64 and aarch64 with
glibc 2.28 or newer. Wheels include the compiled Rust/TVM frontend and the
NumSim engine sources. Compatible Apache TVM and TVM FFI packages are installed
as dependencies. CUDA is not needed to import the package or run CPU simulation.

The package exposes:

- `tirx_harness.synccheck` and `tirx_harness.racecheck`: native correctness checks
- `tirx_harness.numsim`: transpilation and deterministic numerical simulation
- `tirx_harness.dump_kernel`: CUDA, PTX, cubin, and SASS inspection

NumSim compiles each kernel's native artifact on first use. Install Rust 1.89
or newer, Cargo, and a C linker before running simulation or checkers. Source
installation also requires these tools; installing a prebuilt wheel does not.
GPU compilation and source dumping additionally require the CUDA toolkit and
a suitable GPU environment.

## Build from source

From a checkout, install the inner package rather than the root dependency
bundle:

```bash
python -m pip install /absolute/path/to/TIRx-harness/tirx_harness
```

Build isolation installs the pinned TVM FFI build dependency automatically.
The locked native bindings and their license notices are included in the
source distribution; no private GitHub access is required. Cargo downloads
its locked public dependencies during compilation.

The compiler baseline is `apache-tvm==0.27.0`. The full GPU test suite also
requires [the boolean BitwiseNot code-generation fix](https://github.com/apache/tvm/pull/20445).
Use a compatible TVM build containing that fix for those GPU tests.

See the [documentation](https://tirxharness.mlc.ai) and
[source repository](https://github.com/mlc-ai/TIRx-harness) for examples.
