diff options
author | Chris Lattner <sabre@nondot.org> | 2002-12-04 17:32:52 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2002-12-04 17:32:52 +0000 |
commit | fb8032dc840c34b439e38dec20d848b4ac858f1b (patch) | |
tree | c0ae591d160bb04606052de1fe39e5969d7249aa /llvm/lib | |
parent | 8d79e5c9d95418a65c50210c704a2ae475efae71 (diff) | |
download | bcm5719-llvm-fb8032dc840c34b439e38dec20d848b4ac858f1b.tar.gz bcm5719-llvm-fb8032dc840c34b439e38dec20d848b4ac858f1b.zip |
Fix bogus assertion failures
llvm-svn: 4919
Diffstat (limited to 'llvm/lib')
-rw-r--r-- | llvm/lib/Target/X86/MachineCodeEmitter.cpp | 2 | ||||
-rw-r--r-- | llvm/lib/Target/X86/Printer.cpp | 2 | ||||
-rw-r--r-- | llvm/lib/Target/X86/X86CodeEmitter.cpp | 2 |
3 files changed, 3 insertions, 3 deletions
diff --git a/llvm/lib/Target/X86/MachineCodeEmitter.cpp b/llvm/lib/Target/X86/MachineCodeEmitter.cpp index d54da1db40e..4039f34a051 100644 --- a/llvm/lib/Target/X86/MachineCodeEmitter.cpp +++ b/llvm/lib/Target/X86/MachineCodeEmitter.cpp @@ -225,7 +225,7 @@ void Emitter::emitInstruction(MachineInstr &MI) { MCE.emitByte(BaseOpcode + getX86RegNum(MI.getOperand(0).getReg())); if (MI.getNumOperands() == 2) { unsigned Size = 4; - if (Value *V = MI.getOperand(1).getVRegValue()) { + if (Value *V = MI.getOperand(1).getVRegValueOrNull()) { assert(Size == 4 && "Don't know how to emit non-pointer values!"); MCE.emitGlobalAddress(cast<GlobalValue>(V)); } else { diff --git a/llvm/lib/Target/X86/Printer.cpp b/llvm/lib/Target/X86/Printer.cpp index ae14e41d731..bfaa4bd1acd 100644 --- a/llvm/lib/Target/X86/Printer.cpp +++ b/llvm/lib/Target/X86/Printer.cpp @@ -96,7 +96,7 @@ static void printOp(std::ostream &O, const MachineOperand &MO, const MRegisterInfo &RI) { switch (MO.getType()) { case MachineOperand::MO_VirtualRegister: - if (Value *V = MO.getVRegValue()) { + if (Value *V = MO.getVRegValueOrNull()) { O << "<" << V->getName() << ">"; return; } diff --git a/llvm/lib/Target/X86/X86CodeEmitter.cpp b/llvm/lib/Target/X86/X86CodeEmitter.cpp index d54da1db40e..4039f34a051 100644 --- a/llvm/lib/Target/X86/X86CodeEmitter.cpp +++ b/llvm/lib/Target/X86/X86CodeEmitter.cpp @@ -225,7 +225,7 @@ void Emitter::emitInstruction(MachineInstr &MI) { MCE.emitByte(BaseOpcode + getX86RegNum(MI.getOperand(0).getReg())); if (MI.getNumOperands() == 2) { unsigned Size = 4; - if (Value *V = MI.getOperand(1).getVRegValue()) { + if (Value *V = MI.getOperand(1).getVRegValueOrNull()) { assert(Size == 4 && "Don't know how to emit non-pointer values!"); MCE.emitGlobalAddress(cast<GlobalValue>(V)); } else { |