aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib
diff options
context:
space:
mode:
authorJay Foad <jay.foad@amd.com>2022-11-30 10:39:53 +0000
committerJay Foad <jay.foad@amd.com>2022-11-30 18:02:39 +0000
commit3d9e226081cf6a908c27cedf4c0dc72380b62bb2 (patch)
treeb616d60e9164f8adfdbec0669cb53a9faa3919dd /llvm/lib
parentabefd87e706a47303905edcff031a22edf880921 (diff)
downloadllvm-3d9e226081cf6a908c27cedf4c0dc72380b62bb2.zip
llvm-3d9e226081cf6a908c27cedf4c0dc72380b62bb2.tar.gz
llvm-3d9e226081cf6a908c27cedf4c0dc72380b62bb2.tar.bz2
[AMDGPU] Use s_cmp instead of s_cmpk
Don't bother pre-shrinking "s_cmp_lg_u32 reg, 0" to s_cmpk_lg_u32 because 0 is already an inline constant so the s_cmpk form is no smaller. This is just for consistency with the surrounding code and to simplify a downstream patch. Differential Revision: https://reviews.llvm.org/D138993
Diffstat (limited to 'llvm/lib')
-rw-r--r--llvm/lib/Target/AMDGPU/SIISelLowering.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/Target/AMDGPU/SIISelLowering.cpp b/llvm/lib/Target/AMDGPU/SIISelLowering.cpp
index d55b730..0fe6ffc 100644
--- a/llvm/lib/Target/AMDGPU/SIISelLowering.cpp
+++ b/llvm/lib/Target/AMDGPU/SIISelLowering.cpp
@@ -4202,7 +4202,7 @@ MachineBasicBlock *SITargetLowering::EmitInstrWithCustomInserter(
.addImm(0);
}
} else {
- BuildMI(*BB, MII, DL, TII->get(AMDGPU::S_CMPK_LG_U32))
+ BuildMI(*BB, MII, DL, TII->get(AMDGPU::S_CMP_LG_U32))
.addReg(Src2.getReg())
.addImm(0);
}