]> granicus.if.org Git - llvm/commit
[NFC][GlobalISel]: Add a convenience method to MachineInstrBuilder to simplify getOpe...
authorAditya Nandakumar <aditya_nandakumar@apple.com>
Tue, 5 Feb 2019 22:14:40 +0000 (22:14 +0000)
committerAditya Nandakumar <aditya_nandakumar@apple.com>
Tue, 5 Feb 2019 22:14:40 +0000 (22:14 +0000)
commit1c10dc8b9c632bdaec06499c72ab22c389cc6685
tree58f0a14252b09ff4048e06b65b72f4f4d20a0516
parent9b24317c894b51d0cf94c7a0bf9242a4a3097113
[NFC][GlobalISel]: Add a convenience method to MachineInstrBuilder to simplify getOperand(i).getReg()

https://reviews.llvm.org/D57608

It's a common pattern in GISel to have a MachineInstrBuilder from which we get various regs
(commonly MIB->getOperand(0).getReg()). This adds a helper method and the above can be
replaced with MIB.getReg(0).

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@353223 91177308-0d34-0410-b5e6-96231b3b80d8
include/llvm/CodeGen/MachineInstrBuilder.h
lib/Target/AArch64/AArch64InstructionSelector.cpp
lib/Target/AArch64/AArch64LegalizerInfo.cpp