[llvm-commits] CVS: llvm/lib/Target/ARM/ARMTargetAsmInfo.cpp
Evan Cheng
evan.cheng at apple.com
Fri Jan 19 11:00:11 PST 2007
Changes in directory llvm/lib/Target/ARM:
ARMTargetAsmInfo.cpp updated: 1.4 -> 1.5
---
Log message:
Modify emission of jump tables on darwin to emit an extra "l" label that
delimits the boundaries of jump tables. This lets the linker's dead code
stripping optimization do a better job.
---
Diffs of the changes: (+7 -0)
ARMTargetAsmInfo.cpp | 7 +++++++
1 files changed, 7 insertions(+)
Index: llvm/lib/Target/ARM/ARMTargetAsmInfo.cpp
diff -u llvm/lib/Target/ARM/ARMTargetAsmInfo.cpp:1.4 llvm/lib/Target/ARM/ARMTargetAsmInfo.cpp:1.5
--- llvm/lib/Target/ARM/ARMTargetAsmInfo.cpp:1.4 Fri Jan 19 01:51:42 2007
+++ llvm/lib/Target/ARM/ARMTargetAsmInfo.cpp Fri Jan 19 12:59:56 2007
@@ -33,6 +33,13 @@
LCOMMDirective = "\t.lcomm\t";
COMMDirectiveTakesAlignment = false;
+ // In non-PIC modes, emit a special label before jump tables so that the
+ // linker can perform more accurate dead code stripping.
+ if (TM.getRelocationModel() != Reloc::PIC_) {
+ // Emit a local label that is preserved until the linker runs.
+ JumpTableSpecialLabelPrefix = "l";
+ }
+
NeedsSet = true;
DwarfAbbrevSection = ".section __DWARF,__debug_abbrev,regular,debug";
DwarfInfoSection = ".section __DWARF,__debug_info,regular,debug";
More information about the llvm-commits
mailing list