llvm-6502/lib/MC
Saleem Abdulrasool 7afe0000f6 ARM IAS: properly handle function entries in .thumb
When a label is parsed, check if there is type information available for the
label.  If so, check if the symbol is a function.  If the symbol is a function
and we are in thumb mode and no explicit thumb_func has been emitted, adjust the
symbol data to indicate that the function definition is a thumb function.

The application of this inferencing is improved value handling in the object
file (the required thumb bit is set on symbols which are thumb functions).  It
also helps improve compatibility with binutils.

The one complication that arises from this handling is the MCAsmStreamer.  The
default implementation of getOrCreateSymbolData in MCStreamer does not support
tracking the symbol data.  In order to support the semantics of thumb functions,
track symbol data in assembly streamer.  Although O(n) in number of labels in
the TU, this is already done in various other streamers and as such the memory
overhead is not a practical concern in this scenario.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204544 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-22 19:26:18 +00:00
..
MCDisassembler [C++11] Add 'override' keyword to virtual methods that override their base class. 2014-03-08 07:14:16 +00:00
MCParser Remove some dead assignements found by scan-build 2014-03-21 21:54:46 +00:00
CMakeLists.txt Look through variables when computing relocations. 2014-03-20 02:12:01 +00:00
ELFObjectWriter.cpp Fix the value computation in 2014-03-21 22:00:29 +00:00
LLVMBuild.txt
MachObjectWriter.cpp Darwin: Add assembler directives to create version-min load commands. 2014-03-18 22:09:05 +00:00
Makefile
MCAsmBackend.cpp Simplify a really complicated check for Arch == X86_64. 2014-03-11 21:22:57 +00:00
MCAsmInfo.cpp Move get[S|U]LEB128Size() to LEB128.h. 2014-02-22 14:00:39 +00:00
MCAsmInfoCOFF.cpp Re-commit: Demote EmitRawText call in AsmPrinter::EmitInlineAsm() and remove hasRawTextSupport() call 2014-02-13 14:44:26 +00:00
MCAsmInfoDarwin.cpp Re-commit: Demote EmitRawText call in AsmPrinter::EmitInlineAsm() and remove hasRawTextSupport() call 2014-02-13 14:44:26 +00:00
MCAsmInfoELF.cpp
MCAsmStreamer.cpp ARM IAS: properly handle function entries in .thumb 2014-03-22 19:26:18 +00:00
MCAssembler.cpp Darwin: Add assembler directives to create version-min load commands. 2014-03-18 22:09:05 +00:00
MCAtom.cpp
MCCodeEmitter.cpp
MCCodeGenInfo.cpp
MCContext.cpp MC: don't create a backtrace for diagnostics. 2014-03-14 22:41:58 +00:00
MCDisassembler.cpp Change MCDisassembler::setSymbolizer to take unique_ptr by value. 2014-03-07 09:38:02 +00:00
MCDwarf.cpp Don't use EmitAbsValue with symbol references. 2014-03-20 21:26:38 +00:00
MCELF.cpp
MCELFObjectTargetWriter.cpp
MCELFStreamer.cpp Mark alias symbols as microMIPS if necessary. Differential Revision: http://llvm-reviews.chandlerc.com/D3080 2014-03-20 09:44:49 +00:00
MCExpr.cpp Look through variables when computing relocations. 2014-03-20 02:12:01 +00:00
MCExternalSymbolizer.cpp Replace OwningPtr<T> with std::unique_ptr<T>. 2014-03-06 05:51:42 +00:00
MCFixup.cpp Add llvm_unreachable after fully-covered switches to appease GCC 2014-03-20 07:30:40 +00:00
MCFunction.cpp
MCInst.cpp
MCInstPrinter.cpp
MCInstrAnalysis.cpp
MCLabel.cpp
MCMachObjectTargetWriter.cpp
MCMachOStreamer.cpp Darwin: Add assembler directives to create version-min load commands. 2014-03-18 22:09:05 +00:00
MCModule.cpp
MCModuleYAML.cpp Replace OwningPtr<T> with std::unique_ptr<T>. 2014-03-06 05:51:42 +00:00
MCNullStreamer.cpp DebugInfo: Improve reuse of file table entries in asm debug info 2014-03-17 01:52:11 +00:00
MCObjectDisassembler.cpp [C++11] Introduce ObjectFile::symbols() to use range-based loops. 2014-03-17 07:28:19 +00:00
MCObjectFileInfo.cpp MC: Remove superfluous section attribute flag definitions 2014-03-07 07:36:05 +00:00
MCObjectStreamer.cpp Mark alias symbols as microMIPS if necessary. Differential Revision: http://llvm-reviews.chandlerc.com/D3080 2014-03-20 09:44:49 +00:00
MCObjectSymbolizer.cpp [C++11] Introduce ObjectFile::symbols() to use range-based loops. 2014-03-17 07:28:19 +00:00
MCObjectWriter.cpp
MCRegisterInfo.cpp
MCRelocationInfo.cpp
MCSection.cpp
MCSectionCOFF.cpp
MCSectionELF.cpp
MCSectionMachO.cpp MC: Appease the buildbots 2014-03-10 01:04:18 +00:00
MCStreamer.cpp Don't use EmitAbsValue with symbol references. 2014-03-20 21:26:38 +00:00
MCSubtargetInfo.cpp Reverting r199886 (Prevent repetitive warnings for unrecognized processors and features) 2014-01-25 16:56:18 +00:00
MCSymbol.cpp Revert "Add back r203962, r204028 and r204059." 2014-03-19 00:13:43 +00:00
MCSymbolizer.cpp Replace OwningPtr<T> with std::unique_ptr<T>. 2014-03-06 05:51:42 +00:00
MCValue.cpp
MCWin64EH.cpp
SubtargetFeature.cpp Reverting r199886 (Prevent repetitive warnings for unrecognized processors and features) 2014-01-25 16:56:18 +00:00
WinCOFFObjectWriter.cpp [C++11] Add 'override' keyword to virtual methods that override their base class. 2014-03-08 07:02:02 +00:00
WinCOFFStreamer.cpp [C++11] Add 'override' keyword to virtual methods that override their base class. 2014-03-08 07:02:02 +00:00