summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen/GlobalISel/MachineIRBuilder.cpp
diff options
context:
space:
mode:
authorTim Northover <tnorthover@apple.com>2016-08-23 21:01:26 +0000
committerTim Northover <tnorthover@apple.com>2016-08-23 21:01:26 +0000
commit6cd4b23a0fc9cc2f24d996148e170b0a538079d7 (patch)
treef70e16cf6123f81966b6be1c3a163a3b6a98cb11 /llvm/lib/CodeGen/GlobalISel/MachineIRBuilder.cpp
parentb3a0be4d38ab08456aa4406e86d1b6c76581245a (diff)
downloadbcm5719-llvm-6cd4b23a0fc9cc2f24d996148e170b0a538079d7.tar.gz
bcm5719-llvm-6cd4b23a0fc9cc2f24d996148e170b0a538079d7.zip
GlobalISel: legalize integer comparisons on AArch64.
Next step is doing both legalizations at the same time! Marvel at GlobalISel's cunning. llvm-svn: 279566
Diffstat (limited to 'llvm/lib/CodeGen/GlobalISel/MachineIRBuilder.cpp')
-rw-r--r--llvm/lib/CodeGen/GlobalISel/MachineIRBuilder.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/llvm/lib/CodeGen/GlobalISel/MachineIRBuilder.cpp b/llvm/lib/CodeGen/GlobalISel/MachineIRBuilder.cpp
index 5ad75889723..92323895562 100644
--- a/llvm/lib/CodeGen/GlobalISel/MachineIRBuilder.cpp
+++ b/llvm/lib/CodeGen/GlobalISel/MachineIRBuilder.cpp
@@ -146,6 +146,16 @@ MachineInstrBuilder MachineIRBuilder::buildAnyExtend(LLT Ty, unsigned Res,
return buildInstr(TargetOpcode::G_ANYEXTEND, Ty).addDef(Res).addUse(Op);
}
+MachineInstrBuilder MachineIRBuilder::buildSExt(ArrayRef<LLT> Tys, unsigned Res,
+ unsigned Op) {
+ return buildInstr(TargetOpcode::G_SEXT, Tys).addDef(Res).addUse(Op);
+}
+
+MachineInstrBuilder MachineIRBuilder::buildZExt(ArrayRef<LLT> Tys, unsigned Res,
+ unsigned Op) {
+ return buildInstr(TargetOpcode::G_ZEXT, Tys).addDef(Res).addUse(Op);
+}
+
MachineInstrBuilder MachineIRBuilder::buildExtract(ArrayRef<LLT> ResTys,
ArrayRef<unsigned> Results,
ArrayRef<uint64_t> Indices,
OpenPOWER on IntegriCloud