summaryrefslogtreecommitdiffstats
path: root/llvm/tools
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/tools')
-rw-r--r--llvm/tools/llc/llc.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/llvm/tools/llc/llc.cpp b/llvm/tools/llc/llc.cpp
index 9c42f66b893..10fb9f62332 100644
--- a/llvm/tools/llc/llc.cpp
+++ b/llvm/tools/llc/llc.cpp
@@ -401,7 +401,7 @@ static int compileModule(char **argv, LLVMContext &Context) {
if (StringRef(InputFilename).endswith_lower(".mir")) {
MIR = createMIRParserFromFile(InputFilename, Err, Context);
if (MIR)
- M = MIR->parseLLVMModule();
+ M = MIR->parseIRModule();
} else
M = parseIRFile(InputFilename, Err, Context);
if (!M) {
@@ -540,7 +540,8 @@ static int compileModule(char **argv, LLVMContext &Context) {
TPC.setDisableVerify(NoVerify);
PM.add(&TPC);
MachineModuleInfo *MMI = new MachineModuleInfo(&LLVMTM);
- MMI->setMachineFunctionInitializer(MIR.get());
+ if (MIR->parseMachineFunctions(*M, *MMI))
+ return 1;
PM.add(MMI);
TPC.printAndVerify("");
OpenPOWER on IntegriCloud