Depends on D83637 for test correctness, but not operation.
Add handling of s_andn2 and mask of 0.
This eliminates code from uniform control flows.
Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
llvm/lib/Target/AMDGPU/SIPreEmitPeephole.cpp | ||
---|---|---|
129 | Technically here MaskValue can be anything, not just -1 or 0. | |
134 | .. and here you squash it. I think it needs a check. | |
llvm/test/CodeGen/AMDGPU/infinite-loop.ll | ||
161 | Looks like s_mov_b64 vcc, 0? | |
llvm/test/CodeGen/AMDGPU/sgpr-control-flow.ll | ||
14 | Do you mind to pre-commit white space changes? |
llvm/lib/Target/AMDGPU/SIPreEmitPeephole.cpp | ||
---|---|---|
129 | Line 102 ensures MaskValue is 0 or -1. | |
llvm/test/CodeGen/AMDGPU/infinite-loop.ll | ||
161 | Yes, hence how this becomes an unconditional branch. | |
llvm/test/CodeGen/AMDGPU/sgpr-control-flow.ll | ||
14 | Will do. |
llvm/test/CodeGen/AMDGPU/insert-skip-from-vcc.mir | ||
---|---|---|
343–344 | We could switch the entire test to being generate, but generated MIR tests don't use CHECK-NEXT, so these would still fall through the cracks. |
Technically here MaskValue can be anything, not just -1 or 0.