summaryrefslogtreecommitdiffstats
path: root/llvm/lib/MC/WinCOFFObjectWriter.cpp
Commit message (Collapse)AuthorAgeFilesLines
...
* Gas is very inconsistent about when a relaxation/relocation is needed. DoRafael Espindola2011-02-161-20/+0
| | | | | | the right thing and stop trying to copy it. Fixes PR8944. llvm-svn: 125648
* Merge IsFixupFullyResolved and IsSymbolRefDifferenceFullyResolved. We nowRafael Espindola2010-12-241-32/+17
| | | | | | have a single point where targets test if a relocation is needed. llvm-svn: 122549
* Merge isAbsolute into IsSymbolRefDifferenceFullyResolved.Rafael Espindola2010-12-181-14/+0
| | | | llvm-svn: 122148
* Remove the MCObjectFormat class.Rafael Espindola2010-12-181-0/+6
| | | | llvm-svn: 122147
* MC/ObjectWriter: Add a new IsSymbolRefDifferenceFullyResolved target format ↵Daniel Dunbar2010-12-171-0/+8
| | | | | | | | specific hook. - Currently just has stub implementations for Mach-O, ELF, and COFF. llvm-svn: 122037
* MC/Assembler: Strip out object writer arguments, now that it is always availableDaniel Dunbar2010-12-171-1/+1
| | | | | | -- and remove FIXME asking for the same! llvm-svn: 122032
* Sorry for such a large commit. The summary is that only MachO cares about theRafael Espindola2010-12-071-3/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | actuall addresses in a .o file, so it is better to let the MachO writer compute it. This is good for two reasons. First, areas that shouldn't care about addresses now don't have access to it. Second, the layout of each section is independent. I should use this in a subsequent commit to speed it up. Most of the patch is just removing the section address computation. The two interesting parts are the change on how we handle padding in the end of sections and how MachO can get the address of a-b when a and b are in different sections. Since now the expression evaluation normally doesn't know the section address, it will think that a-b needs relocation and let the MachO writer know. Once it has computed the section addresses, it calls back the expression evaluation with the section addresses to resolve these expressions. The remaining problem is the handling of padding. Currently it will create a special alignment fragment at the end. Since that fragment doesn't update the alignment of the section, it needs the real address to be computed. Since now the layout will not compute a-b with a and b in different sections, the only effect that the special alignment fragment has is update the address size of the section. This can also be done by the MachO writer. llvm-svn: 121076
* Use getSymbolOffset on the COFF writer.Rafael Espindola2010-12-061-1/+1
| | | | llvm-svn: 120979
* Merge System into Support.Michael J. Spencer2010-11-291-1/+1
| | | | llvm-svn: 120298
* Define generic 1, 2 and 4 byte pc relative relocations. They are commonRafael Espindola2010-11-281-1/+1
| | | | | | and at least the 4 byte one will be needed to implement the .cfi_* directives. llvm-svn: 120240
* Fix Warnings.Michael J. Spencer2010-10-211-1/+1
| | | | llvm-svn: 117062
* MC-COFF: Add support for default-null weak externals.Michael J. Spencer2010-10-161-45/+57
| | | | llvm-svn: 116666
* MC-COFF: Fix .bss section size. Fixes PR8335. Patch by NAKAMUTA Takumi!Michael J. Spencer2010-10-091-1/+1
| | | | llvm-svn: 116155
* MC-COFF: Assert on non-coff sections.Michael J. Spencer2010-10-091-0/+2
| | | | llvm-svn: 116148
* MC-COFF: Handle relaxation in COFF better. Fixes PR8321.Michael J. Spencer2010-10-071-1/+29
| | | | llvm-svn: 116013
* Fix Punctuation.Michael J. Spencer2010-10-051-1/+1
| | | | llvm-svn: 115657
* MC-COFF: Fix (PR8278) temporary symbol relocations.Michael J. Spencer2010-10-051-1/+2
| | | | llvm-svn: 115656
* On ELF we need to know which symbols are used in relocations to decide ifRafael Espindola2010-10-051-2/+2
| | | | | | | they should be in the symbol table or not. Instead of "guessing", just compute the symbol table after the relocations are known. llvm-svn: 115619
* Correctly produce R_X86_64_32 or R_X86_64_32S.Rafael Espindola2010-09-301-0/+1
| | | | | | | | | | | | | With this patch in movq $foo, foo(%rip) foo: .long foo We produce a R_X86_64_32S for the first relocation and R_X86_64_32 for the second one. llvm-svn: 115134
* Make it possible for the MCObjectWriter to decide if a given fixup is fullyRafael Espindola2010-09-301-0/+12
| | | | | | | | | | | resolved or not. Different object files have different restrictions and different native assemblers have different idiosyncrasies we want to emulate for now. Move the existing MachO logic to the new place and implement an ELF one that gets fixups to globals right. llvm-svn: 115131
* MC-COFF: Fix symbol storage class for globalsMichael J. Spencer2010-09-291-1/+1
| | | | llvm-svn: 115020
* MC-COFF: Fix signed/unsigned comparison.Michael J. Spencer2010-09-271-2/+2
| | | | llvm-svn: 114888
* MC-COFF: Drop empty sections, and label symbols. Convert relocationsMichael J. Spencer2010-09-271-82/+163
| | | | | | | | targeted at symbols into relocations relative to the containing section. Patch by Nathan Jeffords! llvm-svn: 114823
* Fix COFF x86-64 relocations. PR7960.Michael J. Spencer2010-08-241-42/+45
| | | | | | Multiple symbol reloc handling part of the patch by Cameron Esfahani. llvm-svn: 111963
* MC: Add partial x86-64 support to COFF.Michael J. Spencer2010-08-211-17/+43
| | | | llvm-svn: 111728
* MC: Fix symbol fragment offsets in COFF.Michael J. Spencer2010-08-031-1/+2
| | | | | | Patch by Cameron Esfahani! llvm-svn: 110104
* Revert "MC: Fix symbol fragment offsets in COFF."Michael J. Spencer2010-08-031-2/+1
| | | | | | | | This reverts commit r110100 Wrong path caps. llvm-svn: 110103
* MC: Add time travel support to COFF.Michael J. Spencer2010-08-031-0/+4
| | | | llvm-svn: 110101
* MC: Fix symbol fragment offsets in COFF.Michael J. Spencer2010-08-031-1/+2
| | | | | | Patch by Cameron Esfahani! llvm-svn: 110100
* Silence some -Asserts uninitialized variable warnings.Daniel Dunbar2010-07-311-0/+1
| | | | llvm-svn: 109956
* COFFObjectWriter: Don't leak COFFSymbols and COFFSections.Benjamin Kramer2010-07-291-0/+8
| | | | llvm-svn: 109745
* Fix format-specifier warningDouglas Gregor2010-07-261-1/+1
| | | | llvm-svn: 109391
* MC: Fix whitespace error from last commit.Michael J. Spencer2010-07-261-1/+1
| | | | | | A Visual C++ extension that removes trailing new lines? Seriously? llvm-svn: 109390
* MC: Add WinCOFFObjectWriter implementation.Michael J. Spencer2010-07-261-14/+674
| | | | | | Origonal Windows COFF implementation by Nathan Jedffords. llvm-svn: 109389
* introduce WinCOFFObjectWriter, patch by Michael Spencer!Chris Lattner2010-07-111-0/+71
llvm-svn: 108103
OpenPOWER on IntegriCloud