[clang] [llvm] [HLSL][DXIL][SPRIV] Added WaveActiveProduct intrinsic #164385 (PR #165109)
Sietze Riemersma via cfe-commits
cfe-commits at lists.llvm.org
Sat Jan 31 03:03:16 PST 2026
================
@@ -2766,6 +2528,32 @@ bool SPIRVInstructionSelector::selectWaveReduceSum(Register ResVReg,
.addUse(I.getOperand(2).getReg());
}
+bool SPIRVInstructionSelector::selectWaveReduceProduct(Register ResVReg,
----------------
KungFuDonkey wrote:
`selectWaveOpInst` does not take into account the 'reduce' factor of the instruction and does not support multiple instruction types (E.G. float and integer type). I see that WaveActiveSum now has a selectWaveReduce function. I will start using that instead. But I agree, this is tedious. The only way I see how we would implement a single function that could handle all cases would be with a macro.
https://github.com/llvm/llvm-project/pull/165109
More information about the cfe-commits
mailing list