diff --git a/lib/Bytecode/Reader/InstructionReader.cpp b/lib/Bytecode/Reader/InstructionReader.cpp index 2ae21683b5f..603c20564ca 100644 --- a/lib/Bytecode/Reader/InstructionReader.cpp +++ b/lib/Bytecode/Reader/InstructionReader.cpp @@ -405,18 +405,20 @@ bool BytecodeParser::ParseInstruction(const unsigned char *&Buf, return false; } + case 62: // volatile load case Instruction::Load: if (Raw.NumOperands != 1) return true; if (!isa(Raw.Ty)) return true; - Res = new LoadInst(getValue(Raw.Ty, Raw.Arg1)); + Res = new LoadInst(getValue(Raw.Ty, Raw.Arg1), "", Raw.Opcode == 62); return false; + case 63: // volatile store case Instruction::Store: { if (!isa(Raw.Ty) || Raw.NumOperands != 2) return true; Value *Ptr = getValue(Raw.Ty, Raw.Arg2); const Type *ValTy = cast(Ptr->getType())->getElementType(); - Res = new StoreInst(getValue(ValTy, Raw.Arg1), Ptr); + Res = new StoreInst(getValue(ValTy, Raw.Arg1), Ptr, Raw.Opcode == 63); return false; } } // end switch(Raw.Opcode)