diff options
Diffstat (limited to 'llvm/tools/llvm-exegesis/lib/Assembler.cpp')
-rw-r--r-- | llvm/tools/llvm-exegesis/lib/Assembler.cpp | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/llvm/tools/llvm-exegesis/lib/Assembler.cpp b/llvm/tools/llvm-exegesis/lib/Assembler.cpp index ca882cf..1888585 100644 --- a/llvm/tools/llvm-exegesis/lib/Assembler.cpp +++ b/llvm/tools/llvm-exegesis/lib/Assembler.cpp @@ -164,10 +164,9 @@ BitVector getFunctionReservedRegs(const TargetMachine &TM) { std::unique_ptr<Module> Module = createModule(Context, TM.createDataLayout()); // TODO: This only works for targets implementing LLVMTargetMachine. const LLVMTargetMachine &LLVMTM = static_cast<const LLVMTargetMachine &>(TM); - std::unique_ptr<MachineModuleInfoWrapperPass> MMIWP = - std::make_unique<MachineModuleInfoWrapperPass>(&LLVMTM); + auto MMIWP = std::make_unique<MachineModuleInfoWrapperPass>(&LLVMTM); MachineFunction &MF = createVoidVoidPtrMachineFunction( - FunctionID, Module.get(), &MMIWP.get()->getMMI()); + FunctionID, Module.get(), &MMIWP->getMMI()); // Saving reserved registers for client. return MF.getSubtarget().getRegisterInfo()->getReservedRegs(MF); } |