summaryrefslogtreecommitdiffstats
path: root/llvm/lib/MC
Commit message (Collapse)AuthorAgeFilesLines
* For ELF, also call fixSymbolsInTLSFixups() on expressions passed to ↵David Meyer2012-02-151-0/+9
| | | | | | EmitValue (literal values). Previously only called on expressions in instructions. New test cases added to tls.s, tls-i386.s. Resolves PR11981. llvm-svn: 150582
* Add support for implicit TLS model used with MS VC runtime.Anton Korobeynikov2012-02-112-0/+7
| | | | | | Patch by Kai Nacke! llvm-svn: 150307
* Convert assert(0) to llvm_unreachableCraig Topper2012-02-0710-40/+31
| | | | llvm-svn: 149967
* Enable streaming of bitcodeDerek Schuff2012-02-062-4/+4
| | | | | | | This CL delays reading of function bodies from initial parse until materialization, allowing overlap of compilation with bitcode download. llvm-svn: 149918
* Modified the Enhanced Disassembler to create andSean Callanan2012-02-043-31/+40
| | | | | | | | | | cache disassemblers according to the string value of the target triple, not according to the enum of the triple CPU. The reason for this is that certain attributes of the instruction set are not reflected in the enum, but only in the string. llvm-svn: 149773
* Add a new MachineJumpTableInfo entry type, EK_GPRel64BlockAddress, which isAkira Hatanaka2012-02-033-0/+13
| | | | | | | | needed to emit a 64-bit gp-relative relocation entry. Make changes necessary for emitting jump tables which have entries with directive .gpdword. This patch does not implement the parts needed for direct object emission or JIT. llvm-svn: 149668
* Fixed a crash in llvm-mc for Mach-O when a symbol difference expression uses aKevin Enderby2012-01-311-0/+2
| | | | | | | | | symbol from an assignment. In this case the symbol did not have a fragment so MCObjectWriter::IsSymbolRefDifferenceFullyResolved() should not have been calling IsSymbolRefDifferenceFullyResolvedImpl() with a NULL fragment and should just have returned false in that case. llvm-svn: 149442
* Add assembler dialect attribute in asm parser which lets target specific asm ↵Devang Patel2012-01-311-2/+14
| | | | | | parser change dialect on the fly. llvm-svn: 149396
* Silence GCC's -Wreturn-type warning.Benjamin Kramer2012-01-281-0/+3
| | | | llvm-svn: 149179
* Small improvement to the recursion detection logic from the previous commit.Rafael Espindola2012-01-281-1/+3
| | | | llvm-svn: 149175
* Handle recursive variable definitions directly. This gives us better errorRafael Espindola2012-01-281-11/+15
| | | | | | messages and allows us to fix PR11865. llvm-svn: 149174
* Source information in 'expected relocatable expression' diagnostic.Jim Grosbach2012-01-271-1/+1
| | | | llvm-svn: 149105
* Better diagnostic for malformed .org assembly directive.Jim Grosbach2012-01-275-12/+18
| | | | | | Provide source line number information. llvm-svn: 149101
* Tidy up.Jim Grosbach2012-01-261-1/+1
| | | | llvm-svn: 149096
* Add simple support for keeping MCFixup source information.Jim Grosbach2012-01-261-0/+19
| | | | | | | Can be used to issue more user friendly diagnostics for faulty relocation constructs and such. llvm-svn: 149092
* Add SourceMgr to MCContext for backend diagnostics.Jim Grosbach2012-01-261-2/+2
| | | | llvm-svn: 149090
* Add support for the R_ARM_TARGET1 relocation, which should be given to ↵James Molloy2012-01-261-1/+3
| | | | | | | | relocations applied to all C++ constructors and destructors. This enables the linker to match concrete relocation types (absolute or relative) with whatever library or C++ support code is being linked against. llvm-svn: 149057
* Properly emit ctors / dtors with priorities into desired sectionsAnton Korobeynikov2012-01-251-7/+1
| | | | | | | | and let linker handle the rest. This finally fixes PR5329 llvm-svn: 148990
* ARM Darwin symbol ref differences w/o subsection-via-symbols.Jim Grosbach2012-01-241-1/+2
| | | | | | | | When not using subsections via symbols, the assembler can resolve symbol differences (including pcrel references) to non-local labels at assembly time, not just those in the same atom. llvm-svn: 148865
* Add support for .cfi_signal_frame. Fixes pr11762.Rafael Espindola2012-01-234-7/+48
| | | | llvm-svn: 148733
* More dead code removal (using -Wunreachable-code)David Blaikie2012-01-205-8/+2
| | | | llvm-svn: 148578
* Add missing breaks to switch.Benjamin Kramer2012-01-201-13/+25
| | | | | | Found by the clang static analyzer. llvm-svn: 148543
* Remove a bunch of unused variable assignments.Benjamin Kramer2012-01-201-9/+2
| | | | | | Found by the clang static analyzer. llvm-svn: 148541
* Add a dump() implementation for sub-instruction MCOperands.Owen Anderson2012-01-191-0/+2
| | | | llvm-svn: 148493
* MCAssembler tweak for determining when a symbol difference is resolved.Jim Grosbach2012-01-181-1/+2
| | | | | | | | | | | | If the two fragments are in the same Atom, then the difference expression is resolvable at compile time. Previously we were checking that they were in the same fragment, but that breaks down in the presence of instruction relaxation which has multiple fragments in the same atom. rdar://10711829 llvm-svn: 148423
* Tidy up. MCAsmBackend naming conventions.Jim Grosbach2012-01-183-10/+10
| | | | llvm-svn: 148400
* Move some ARM specific MCAssmebler bits into the ARMAsmBackend.Jim Grosbach2012-01-181-9/+2
| | | | llvm-svn: 148364
* MC tweak symbol difference resolution for non-local symbols.Jim Grosbach2012-01-171-2/+2
| | | | | | | | | | | | | | When the non-local symbol in the expression is in the same fragment as the second symbol, the assembler can still evaluate the expression without needing a relocation. For example, on ARM: _foo: ldr lr, (_foo - 4) rdar://10348687 llvm-svn: 148341
* The error check for using -g with a .s file already containing dwarf .fileKevin Enderby2012-01-111-4/+4
| | | | | | | directives was in the wrong place and getting triggered incorectly with a cpp .file directive. This change fixes that and adds a test case. llvm-svn: 147951
* Let asm parser query asm syntax dialect.Devang Patel2012-01-101-0/+1
| | | | llvm-svn: 147880
* This is the matching change for the data structure name changes for theKevin Enderby2012-01-102-21/+21
| | | | | | | functional change in r147860 to use DW_TAG_label's instead TAG_subprogram's. This only changes names and updates comments. No functional change. llvm-svn: 147877
* Fix some leftover control reaches end of non-void function warnings.Benjamin Kramer2012-01-101-6/+5
| | | | llvm-svn: 147874
* Add 'llvm_unreachable' to passify GCC's understanding of the constraintsChandler Carruth2012-01-101-0/+2
| | | | | | | | of several newly un-defaulted switches. This also helps optimizers (including LLVM's) recognize that every case is covered, and we should assume as much. llvm-svn: 147861
* Various crash reporting tools have a problem with the dwarf generated forKevin Enderby2012-01-101-17/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | assembly source when it generates the TAG_subprogram dwarf debug info for the labels that have nothing between them as in this bit of assembly source: % cat ZeroLength.s _func1: _func2: nop One solution would be to not emit the subsequent labels with the same address and use the next label with a different address or the end of the section for the AT_high_pc value of the TAG_subprogram. Turns out in llvm-mc it is not possible in all cases to determine of two symbols have the same value at the point we put out the TAG_subprogram dwarf debug info. So we will have llvm-mc instead of putting out TAG_subprogram's put out DW_TAG_label's. And the DW_TAG_label does not have a AT_high_pc value which avoids the problem. This commit is only the functional change to make the diffs clear as to what is really being changed. The next commit will be to clean up the names of such things like MCGenDwarfSubprogramEntry to something like MCGenDwarfLabelEntry. rdar://10666925 llvm-svn: 147860
* Remove unnecessary default cases in switches that cover all enum values.David Blaikie2012-01-104-8/+0
| | | | llvm-svn: 147855
* Remove the logging streamer.Rafael Espindola2012-01-102-258/+0
| | | | llvm-svn: 147820
* Don't print an unused label before .cfi_endproc.Rafael Espindola2012-01-093-7/+22
| | | | llvm-svn: 147763
* Remove MCELFStreamer.h.Rafael Espindola2012-01-072-143/+121
| | | | llvm-svn: 147745
* Don't print a label before .cfi_startproc when we don't need to. This makesRafael Espindola2012-01-073-9/+19
| | | | | | the produce assembly when using CFI just a bit more readable. llvm-svn: 147743
* Split Finish into Finish and FinishImpl to have a common place to do end ofRafael Espindola2012-01-0710-19/+26
| | | | | | | | file error checking. Use that to error on an unfinished cfi_startproc. The error is not nice, but is already better than a segmentation fault. llvm-svn: 147717
* Implement cfi_restore. Patch by Brian Anderson!Rafael Espindola2011-12-293-0/+34
| | | | llvm-svn: 147356
* Rename Remember and Restore to RememberState and RestoreState for consistency.Rafael Espindola2011-12-292-4/+4
| | | | llvm-svn: 147354
* Implement .cfi_escape. Patch by Brian Anderson!Rafael Espindola2011-12-293-0/+40
| | | | llvm-svn: 147352
* Section relative fixups are a coff concept, not a x86 one. Replace theRafael Espindola2011-12-242-4/+6
| | | | | | x86 specific reloc_coff_secrel32 with a generic FK_SecRel_4. llvm-svn: 147252
* Move x86 specific bits of the COFF writer to lib/Target/X86.Rafael Espindola2011-12-241-39/+17
| | | | llvm-svn: 147231
* Define trivial destructor inline.Rafael Espindola2011-12-241-3/+0
| | | | llvm-svn: 147230
* Make GetRelocType pure virtual.Rafael Espindola2011-12-241-8/+0
| | | | llvm-svn: 147229
* Move all the dependencies on X86FixupKinds.h to a single method in preparationRafael Espindola2011-12-221-27/+34
| | | | | | to moving it to lib/Target/X86. llvm-svn: 147190
* Kill the monstrosity that was ELFObjectWriter.h.Rafael Espindola2011-12-222-361/+331
| | | | llvm-svn: 147136
* Misc cleanups.Rafael Espindola2011-12-222-76/+58
| | | | llvm-svn: 147135
OpenPOWER on IntegriCloud