[llvm-commits] CVS: llvm/lib/Target/X86/X86IntelAsmPrinter.cpp X86TargetAsmInfo.cpp
Anton Korobeynikov
asl at math.spbu.ru
Tue Dec 19 13:04:37 PST 2006
Changes in directory llvm/lib/Target/X86:
X86IntelAsmPrinter.cpp updated: 1.65 -> 1.66
X86TargetAsmInfo.cpp updated: 1.12 -> 1.13
---
Log message:
Fix for PR1059: http://llvm.org/PR1059 : http://llvm.org/PR1059: http://llvm.org/PR1059
---
Diffs of the changes: (+10 -2)
X86IntelAsmPrinter.cpp | 11 +++++++++--
X86TargetAsmInfo.cpp | 1 +
2 files changed, 10 insertions(+), 2 deletions(-)
Index: llvm/lib/Target/X86/X86IntelAsmPrinter.cpp
diff -u llvm/lib/Target/X86/X86IntelAsmPrinter.cpp:1.65 llvm/lib/Target/X86/X86IntelAsmPrinter.cpp:1.66
--- llvm/lib/Target/X86/X86IntelAsmPrinter.cpp:1.65 Tue Dec 19 13:29:58 2006
+++ llvm/lib/Target/X86/X86IntelAsmPrinter.cpp Tue Dec 19 15:04:20 2006
@@ -113,7 +113,7 @@
const char *Modifier) {
const MRegisterInfo &RI = *TM.getRegisterInfo();
switch (MO.getType()) {
- case MachineOperand::MO_Register:
+ case MachineOperand::MO_Register: {
if (MRegisterInfo::isPhysicalRegister(MO.getReg())) {
unsigned Reg = MO.getReg();
if (Modifier && strncmp(Modifier, "subreg", strlen("subreg")) == 0) {
@@ -126,13 +126,20 @@
} else
O << "reg" << MO.getReg();
return;
-
+ }
case MachineOperand::MO_Immediate:
O << MO.getImmedValue();
return;
case MachineOperand::MO_MachineBasicBlock:
printBasicBlockLabel(MO.getMachineBasicBlock());
return;
+ case MachineOperand::MO_JumpTableIndex: {
+ bool isMemOp = Modifier && !strcmp(Modifier, "mem");
+ if (!isMemOp) O << "OFFSET ";
+ O << TAI->getPrivateGlobalPrefix() << "JTI" << getFunctionNumber()
+ << "_" << MO.getJumpTableIndex();
+ return;
+ }
case MachineOperand::MO_ConstantPoolIndex: {
bool isMemOp = Modifier && !strcmp(Modifier, "mem");
if (!isMemOp) O << "OFFSET ";
Index: llvm/lib/Target/X86/X86TargetAsmInfo.cpp
diff -u llvm/lib/Target/X86/X86TargetAsmInfo.cpp:1.12 llvm/lib/Target/X86/X86TargetAsmInfo.cpp:1.13
--- llvm/lib/Target/X86/X86TargetAsmInfo.cpp:1.12 Fri Dec 1 14:47:11 2006
+++ llvm/lib/Target/X86/X86TargetAsmInfo.cpp Tue Dec 19 15:04:20 2006
@@ -152,6 +152,7 @@
TextSection = "_text";
DataSection = "_data";
+ JumpTableDataSection = NULL;
SwitchToSectionDirective = "";
TextSectionStartSuffix = "\tsegment 'CODE'";
DataSectionStartSuffix = "\tsegment 'DATA'";
More information about the llvm-commits
mailing list