[llvm] [AMDGPU] V_SET_INACTIVE optimizations (PR #98864)
Jay Foad via llvm-commits
llvm-commits at lists.llvm.org
Sat Sep 7 05:23:03 PDT 2024
================
@@ -555,16 +559,24 @@ char SIWholeQuadMode::scanInstructions(MachineFunction &MF,
GlobalFlags |= StateStrictWQM;
} else if (Opcode == AMDGPU::V_SET_INACTIVE_B32 ||
Opcode == AMDGPU::V_SET_INACTIVE_B64) {
- III.Disabled = StateStrict;
- MachineOperand &Inactive = MI.getOperand(2);
- if (Inactive.isReg()) {
- if (Inactive.isUndef()) {
- LowerToCopyInstrs.push_back(&MI);
- } else {
- markOperand(MI, Inactive, StateStrictWWM, Worklist);
+ // Ignore these if V_SET_INACTIVE which already has exec src register.
+ // These are generated by an earlier pass which has seperately ensured
+ // WWM and provided a mask of inactive lanes.
----------------
jayfoad wrote:
@perlfu what's the point of this? As far as I can tell it only happens with the hand written MIR test that you added (preloaded_set_inactive in wqm.mir).
https://github.com/llvm/llvm-project/pull/98864
More information about the llvm-commits
mailing list