ARM Fixups relative to thumb functions need to have the low bit of the value
[oota-llvm.git] / lib / MC / MCMachOStreamer.cpp
index df1e7d8e2b5ac35190d5b8977372694b4bb17897..0e21f4d00c14271f6ef19b9634747dda8c77dd1a 100644 (file)
@@ -142,6 +142,10 @@ void MCMachOStreamer::EmitAssemblerFlag(MCAssemblerFlag Flag) {
 
 void MCMachOStreamer::EmitThumbFunc(MCSymbol *Func) {
   // FIXME: Flag the function ISA as thumb with DW_AT_APPLE_isa.
+
+  // Remember that the function is a thumb function. Fixup and relocation
+  // values will need adjusted.
+  getAssembler().setIsThumbFunc(Func);
 }
 
 void MCMachOStreamer::EmitAssignment(MCSymbol *Symbol, const MCExpr *Value) {