Skip to content

fix: Respect native Orin CUDA architecture and CuTe link requirements - #118

Open
suharvest wants to merge 2 commits into
NVIDIA:mainfrom
suharvest:pr/jetson-build-compat
Open

fix: Respect native Orin CUDA architecture and CuTe link requirements#118
suharvest wants to merge 2 commits into
NVIDIA:mainfrom
suharvest:pr/jetson-build-compat

Conversation

@suharvest

@suharvest suharvest commented Jun 28, 2026

Copy link
Copy Markdown

What does this PR do?

Fixes the two CMake propagation issues reported in #117 that block a native
Jetson Orin build with JetPack 6 / CUDA 12.6:

  1. Capture an explicitly supplied CMAKE_CUDA_ARCHITECTURES before
    project() enables CUDA, so the project default no longer replaces
    -DCMAKE_CUDA_ARCHITECTURES=87.
  2. For CuTe DSL link targets that are static libraries, propagate the cudart
    shim with PUBLIC scope and the CUDA 12.0–12.6
    -Wl,--wrap=_cudaLaunchKernelEx option with INTERFACE scope. The existing
    behavior for non-static targets is unchanged.

This branch has been rebuilt on the current v0.9.1 main
(7f061f21f0a581ba234a1e233c9315b89d8e47d6). The v0.8-era patch was not
blindly rebased because cmake/CuteDsl.cmake changed substantially in v0.9.1.

Scope

  • Two CMake files only.
  • No runtime, model, kernel, or API changes.
  • CUDA_DRIVER_LIB remains PRIVATE; this PR does not expand its transitive
    link scope.
  • Default x86 architecture selection and the AArch64 toolchain path retain
    their existing behavior.

Validation

  • Focused CMake checks cover explicit SM87, default native, and AArch64
    toolchain architecture selection.
  • A focused harness including the updated cmake/CuteDsl.cmake verifies that a
    static consumer exposes the CuTe archive and shim through
    INTERFACE_LINK_LIBRARIES, and exposes --wrap=_cudaLaunchKernelEx through
    INTERFACE_LINK_OPTIONS.
  • The same harness verifies that CUDA_DRIVER_LIB remains private.
  • git diff --check passes.
  • A merge-tree check against current main is clean.

A native Orin build and the repository-wide pre-commit suite were not rerun on
the machine used for this v0.9.1 rebase because it has no CUDA/Jetson toolchain
or repository pre-commit environment. CI or Jetson validation is therefore
still requested.

Closes #117.

@suharvest
suharvest requested a review from a team June 28, 2026 23:45
@rickwalder

rickwalder commented Jul 1, 2026

Copy link
Copy Markdown

+1, this fixes jetson AGX orin build for me (jp 6.2.1)

Signed-off-by: suharvest <suharvest@gmail.com>
Signed-off-by: suharvest <suharvest@gmail.com>
@suharvest
suharvest force-pushed the pr/jetson-build-compat branch from 29d18b7 to b406116 Compare July 25, 2026 11:25
@suharvest suharvest changed the title Fix native Jetson Orin (sm_87) build: respect explicit CUDA arch + propagate CuTe DSL --wrap/shim to static-lib consumers fix: Respect native Orin CUDA architecture and CuTe link requirements Jul 25, 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.

[Bug] Native Jetson Orin (sm_87) build: explicit -DCMAKE_CUDA_ARCHITECTURES ignored + CuTe DSL --wrap/cudart shim not propagated to static-lib consumers

2 participants