Module Ir.Cuda_like_config

val cuda_fast_math : unit -> Base.bool

CUDA's math policy (gh-ocannl-1710): whether nvrtc compiles with --use_fast_math (Compiler_options.nvrtc_math_options) and f32 Tanh_approx renders the __tanhf intrinsic. On by default; profile=reproducible turns it off. The one reader of the key, so the compile, the rendering and the CUDA schedule-cache regime cannot disagree.

val hip_fast_math : unit -> Base.bool

HIP's math policy (gh-ocannl-1779): whether hiprtc compiles with -ffast-math (Compiler_options.hip_math_options). On by default; profile=reproducible turns it off. The one reader of the key, so the compile and the HIP schedule-cache regime cannot disagree. Unlike CUDA's, it changes no rendering: Builtins_hip's wrappers are IEEE under either state.

module Cuda : sig ... end
module Hip : sig ... end
module Make (Dialect : sig ... end) (Input : sig ... end) : sig ... end

Shared CUDA/HIP scalar semantics. Hardware MMA, asynchronous copies and conversions with different vendor overload contracts stay in the backend; the common operator table lives here so fixes to narrow arithmetic reach both consumers.