Index: lib/Target/ARM/ARMSubtarget.cpp |
=================================================================== |
--- lib/Target/ARM/ARMSubtarget.cpp (revision 78188) |
+++ lib/Target/ARM/ARMSubtarget.cpp (working copy) |
@@ -21,6 +21,16 @@ |
ReserveR9("arm-reserve-r9", cl::Hidden, |
cl::desc("Reserve R9, making it unavailable as GPR")); |
+// TODO: * This does not currently work as expected for PIC mode: |
+// It does work, but the table still ends up in the .text section. |
+// * JITing has not been tested at all |
+// * Thumb mode operation is also not clear: it seems jump tables |
+// for thumb are broken independent of this option |
+static cl::opt<bool> |
+NoInlineJumpTables("no-inline-jumptables", |
+ cl::desc("Do not place jump tables inline in the code")); |
+ |
+ |
ARMSubtarget::ARMSubtarget(const std::string &TT, const std::string &FS, |
bool isThumb) |
: ARMArchVersion(V4T) |
@@ -29,6 +39,7 @@ |
, IsThumb(isThumb) |
, ThumbMode(Thumb1) |
, IsR9Reserved(ReserveR9) |
+ , UseInlineJumpTables(!NoInlineJumpTables) |
, stackAlignment(4) |
, CPUString("generic") |
, TargetType(isELF) // Default to ELF unless otherwise specified. |