[AMDGPU] Fold immediates in the optimizeCompareInstr
authorStanislav Mekhanoshin <Stanislav.Mekhanoshin@amd.com>
Thu, 2 Sep 2021 20:06:26 +0000 (13:06 -0700)
committerStanislav Mekhanoshin <Stanislav.Mekhanoshin@amd.com>
Fri, 3 Sep 2021 00:23:26 +0000 (17:23 -0700)
commit2cfda6a6912e140bc02f569aa7992deed7b54ea9
treeb08905878d2c545337f65514c03ba9405db96e1a
parentc32884c482ca3a742afaaa883a369918bb2eeb3f
[AMDGPU] Fold immediates in the optimizeCompareInstr

Peephole works before the first SIFoldOperands so most of
the immediates are in registers.

Differential Revision: https://reviews.llvm.org/D109186
llvm/lib/Target/AMDGPU/SIInstrInfo.cpp
llvm/lib/Target/AMDGPU/SIInstrInfo.h
llvm/test/CodeGen/AMDGPU/basic-branch.ll
llvm/test/CodeGen/AMDGPU/optimize-compare.mir
llvm/test/CodeGen/AMDGPU/setcc.ll
llvm/test/CodeGen/AMDGPU/wave32.ll