[clang] [llvm] [HLSL][DXIL][SPRIV] Added WaveActiveMin intrinsic (PR #164385)
    Sietze Riemersma via llvm-commits 
    llvm-commits at lists.llvm.org
       
    Fri Oct 24 11:10:05 PDT 2025
    
    
  
KungFuDonkey wrote:
```
opt.exe -S -scalarizer -dxil-op-lower -mtriple=dxil-pc-shadermodel6.3-library < C:\develop\personal_gh\llvm-project\llvm\test\CodeGen\DirectX\WaveActiveMin.ll | c:\develop\personal_gh\llvm-project\build\bin\filecheck.exe C:\develop\personal_gh\llvm-project\llvm\test\CodeGen\DirectX\WaveActiveMin.ll
Intrinsic has incorrect return type!
ptr @llvm.dx.wave.reduce.min.f32
```
from:
```
define noundef float @wave_active_min_half(float noundef %expr) {
entry:
; CHECK: call float @dx.op.waveActiveOp.f32(i32 119, float %expr, i8 2, i8 0){{$}}
  %ret = call float @llvm.dx.wave.reduce.min.f32(float %expr)
  ret float %ret
}
```
This happens for all float types. I cannot find where dx is handling floats for WaveActiveMax
https://github.com/llvm/llvm-project/pull/164385
    
    
More information about the llvm-commits
mailing list