Skip to content

fix: align device list with InfiniRT master#792

Closed
voltjia wants to merge 1 commit into
masterfrom
fix/infinirt-master-build
Closed

fix: align device list with InfiniRT master#792
voltjia wants to merge 1 commit into
masterfrom
fix/infinirt-master-build

Conversation

@voltjia

@voltjia voltjia commented Jul 10, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • Remove hard-coded kKunlun and kQy device references from active device lists, PyTorch backend instantiations, wrapper codegen, and docs examples.
  • Align generated wrapper device mapping with the device enum exported by current InfiniRT master.

Motivation

Current InfiniOps master fails to build against current InfiniRT master because InfiniOps still references Device::Type::kKunlun and Device::Type::kQy, which are no longer exported by InfiniRT master. This blocks NVIDIA smoke builds with WITH_TORCH=ON, including the reduced PyTorch backend operator set.

Closes #

Type of Change

  • feat - new feature / new operator / new platform
  • fix - bug fix
  • perf - performance improvement (no behavioral change)
  • refactor - code restructuring without behavior change
  • test - adding or fixing tests only
  • docs - documentation only
  • build / ci - build system or CI configuration
  • chore - tooling, formatting, or other non-code changes
  • Breaking change (requires a ! in the Conventional Commits prefix or a BREAKING CHANGE: footer)

Platforms Affected

  • CPU (WITH_CPU)
  • NVIDIA (WITH_NVIDIA)
  • Iluvatar (WITH_ILUVATAR)
  • MetaX (WITH_METAX)
  • Cambricon (WITH_CAMBRICON)
  • Moore (WITH_MOORE)
  • Ascend (WITH_ASCEND)
  • PyTorch C++ bindings (WITH_TORCH)
  • Build system / CMake / CI
  • Python bindings / user-facing API

Smoke Test Result

# ssh nvidia, accelerator-dev/nvidia:latest
# InfiniRT master: 0f0d61f
# InfiniOps branch: fix/infinirt-master-build

python3 -m py_compile scripts/generate_torch_ops.py scripts/generate_wrappers.py
git diff --check

scripts/dev/build.sh nvidia --smoke --jobs 4 --torch-jobs 1 --binding-jobs 1
...
-- Wrapper op allowlist: add;mul;cast;cat;gemm;matmul;linear;rms_norm;swiglu;causal_softmax;abs;clamp;exp
-- Codegen schema: PyTorch v2.10.0a0
-- Codegen torch op allowlist: abs;clamp;exp
generated 4 overloads across 3 ops: ['abs', 'clamp', 'exp']
-- Generating torch op wrappers - done
-- Torch unity build: 5 sources batched into 1 translation units
-- Generating wrappers - done
[11/12] Linking CUDA shared module src/ops.cpython-312-x86_64-linux-gnu.so
[build] done

PYTHONPATH=/workspace/InfiniOps/build-nvidia/install python3 -m pytest tests -m smoke -q --devices nvidia --tb=short
Running 56 items in this shard
......ssss..ss.............................ssssss.......                 [100%]
44 passed, 12 skipped, 6859 deselected in 8.41s

Test Results on Supported Platforms

Platform Affected Build / Smoke Result Full Result / Notes
NVIDIA Yes smoke passed Full suite not run; smoke build and smoke tests passed in accelerator-dev/nvidia:latest.
Iluvatar No N/A - not affected Device enum alignment only; not run locally.
MetaX No N/A - not affected Device enum alignment only; not run locally.
Cambricon No N/A - not affected Device enum alignment only; not run locally.
Moore No N/A - not affected Device enum alignment only; not run locally.
Ascend No N/A - not affected Device enum alignment only; not run locally.
Full `pytest` output (optional)
Running 56 items in this shard
......ssss..ss.............................ssssss.......                 [100%]
44 passed, 12 skipped, 6859 deselected in 8.41s

Benchmark / Performance Impact

N/A - build compatibility fix only.

Notes for Reviewers

This PR intentionally follows the device enum currently exported by InfiniRT master. It does not add replacement support for removed kunlun or qy device names.

@voltjia voltjia requested a review from a team July 10, 2026 04:58
@voltjia

voltjia commented Jul 10, 2026

Copy link
Copy Markdown
Collaborator Author

Closing as duplicate of #790. The patch content is identical, and #790 has already been merged into master.

@voltjia voltjia closed this Jul 10, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant