================ @@ -428,6 +431,7 @@ bool SPIRVInstructionSelector::spvSelect(Register ResVReg, case TargetOpcode::G_INTRINSIC: case TargetOpcode::G_INTRINSIC_W_SIDE_EFFECTS: + case TargetOpcode::G_INTRINSIC_CONVERGENT: ---------------- s-perron wrote:
The extra convergence information is being used when we generate the merge instructions. They should not change how the instrinsic itself is generated. The convergence token help us distinguish between: ``` int i; for(i = 0; i < N; ++i) { if (cond(i)) { // The "active" lanes are those where cond was true in the same iteration. WaveReadLaneAt(i); break; } } for(i = 0; i < N; ++i) { if (cond(i)) break; } // All lanes are active because they all reconverged at the end of the loop. WaveReadLaneAt(i); ``` https://github.com/llvm/llvm-project/pull/111010 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits