Skip to content

Integrate an optional cuda-oxide RMSNorm path with MLX execution #2833

Done

Description

@inureyes

Problem / Background

Loading precompiled PTX is insufficient: MLX must own evaluation timing, array lifetimes, and graph dependencies. Depends on #2832 and #2831.

Design: feasibility review, added in #2835. Integration points: kernels/fused_norm.cpp, kernels/kernel_port.h, CUDA jit_module.cpp and device.cpp under src/lib/mlxcelverse/, and src/lib/mlxcel-core/build.rs.

Proposed Solution

Add a default-off experimental adapter for the standalone fused-normalization artifact. Preserve the current CUDA implementation and backend dispatch. Use the same artifact/ABI manifest as the standalone harness; validate target and specialization before enqueue.

Acceptance Criteria

  • Execute during MLX lazy evaluation through its command encoder; retain inputs, outputs, and modules until asynchronous completion and graph replay finish, without device-host-device tensor round trips.
  • Test lazy chains, graph on/off, repeated replay, allocator reuse, concurrent requests/streams, and captured-child-graph dependency ordering with nonzero GPU execution.
  • Preserve artifact/dtype/shape/target/ABI cache identity and existing cache trust rules; test wrong-manifest, missing-artifact, unsupported-dtype/layout/target cases.
  • Unsupported configurations select the existing CUDA path before enqueue; execution-time CUDA faults surface as errors, never silent retries. Expose a test-visible route marker so parity cannot pass by unnoticed fallback.
  • Run the numerical matrix from Add a standalone cuda-oxide fused residual RMSNorm kernel #2832 in the adapter and demonstrate unchanged ordinary builds without oxide artifacts/compiler; keep non-CUDA and Windows routes unchanged.
  • Record GB10 commands/results under gpu-lock and document the opt-in switch and fallback behavior.

No general runtime replacement, broad operator port, or production enablement. If correct integration requires backend replacement, report the constraint and stop expansion.

Implemented in PR #3451 (open, not merged); commands and results are in docs/mlxcelverse/cuda-oxide-mlx-adapter-evidence.md on that branch. No backend replacement was needed.

Activity

  1. added
    status:blocked
    type:enhancement
    priority:medium
    area:core
    platform:linux
    on Nov 2, 2026
  2. added
    status:ready
    status:in-progress
    and removed
    status:blocked
    status:ready
    on Nov 26, 2026
  3. added
    status:review
    and removed
    status:in-progress
    on Nov 26, 2026
  4. added
    status:done
    and removed
    status:review
    on Nov 26, 2026
  5. added a commit that references this issue on Nov 27, 2026
    2f39471
  6. added this to the 0.9 milestone on Nov 30, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    area:coreplatform:linuxpriority:mediumstatus:donetype:enhancement

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions