summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen/MIRParser/MIParser.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/lib/CodeGen/MIRParser/MIParser.cpp')
-rw-r--r--llvm/lib/CodeGen/MIRParser/MIParser.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/llvm/lib/CodeGen/MIRParser/MIParser.cpp b/llvm/lib/CodeGen/MIRParser/MIParser.cpp
index af599a5cc3b..8874aaedfcf 100644
--- a/llvm/lib/CodeGen/MIRParser/MIParser.cpp
+++ b/llvm/lib/CodeGen/MIRParser/MIParser.cpp
@@ -1125,12 +1125,16 @@ bool MIParser::parseMachineMemoryOperand(MachineMemOperand *&Dest) {
if (!V->getType()->isPointerTy())
return error("expected a pointer IR value");
lex();
+ int64_t Offset = 0;
+ if (parseOffset(Offset))
+ return true;
// TODO: Parse the base alignment.
// TODO: Parse the attached metadata nodes.
if (expectAndConsume(MIToken::rparen))
return true;
- Dest = MF.getMachineMemOperand(MachinePointerInfo(V), Flags, Size, Size);
+ Dest =
+ MF.getMachineMemOperand(MachinePointerInfo(V, Offset), Flags, Size, Size);
return false;
}
OpenPOWER on IntegriCloud