[llvm-commits] CVS: llvm/lib/Target/PowerPC/PPCCodeEmitter.cpp
Chris Lattner
lattner at cs.uiuc.edu
Sat Dec 10 23:37:53 PST 2005
Changes in directory llvm/lib/Target/PowerPC:
PPCCodeEmitter.cpp updated: 1.41 -> 1.42
---
Log message:
Fix the JIT failures from last night.
---
Diffs of the changes: (+2 -1)
PPCCodeEmitter.cpp | 3 ++-
1 files changed, 2 insertions(+), 1 deletion(-)
Index: llvm/lib/Target/PowerPC/PPCCodeEmitter.cpp
diff -u llvm/lib/Target/PowerPC/PPCCodeEmitter.cpp:1.41 llvm/lib/Target/PowerPC/PPCCodeEmitter.cpp:1.42
--- llvm/lib/Target/PowerPC/PPCCodeEmitter.cpp:1.41 Tue Nov 15 18:48:01 2005
+++ llvm/lib/Target/PowerPC/PPCCodeEmitter.cpp Sun Dec 11 01:37:41 2005
@@ -242,11 +242,12 @@
unsigned index = MO.getConstantPoolIndex();
unsigned Opcode = MI.getOpcode();
rv = MCE.getConstantPoolEntryAddress(index);
- if (Opcode == PPC::LIS) {
+ if (Opcode == PPC::LIS || Opcode == PPC::ADDIS) {
// lis wants hi16(addr)
if ((short)rv < 0) rv += 1 << 16;
rv >>= 16;
} else if (Opcode == PPC::LWZ || Opcode == PPC::LA ||
+ Opcode == PPC::LI ||
Opcode == PPC::LFS || Opcode == PPC::LFD) {
// These load opcodes want lo16(addr)
rv &= 0xffff;
More information about the llvm-commits
mailing list