1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-22 12:33:33 +02:00
Commit Graph

633 Commits

Author SHA1 Message Date
Bill Wendling
da6d7dd741 Get rid of "passing signed into unsigned parameter" warning on PPC.
llvm-svn: 112995
2010-09-03 19:09:46 +00:00
Benjamin Kramer
dd16ed1618 Add AsmParser support for the ELF .previous directive. Patch by Roman Divacky.
llvm-svn: 112849
2010-09-02 18:53:37 +00:00
Benjamin Kramer
4d2c506037 Allow MCSA_WeakRef in ELF. Patch by Roman Divacky.
llvm-svn: 112834
2010-09-02 17:18:32 +00:00
Devang Patel
bbbd35d042 Fix .debug_range for linux. Patch by Krister Wombell.
llvm-svn: 112830
2010-09-02 16:43:44 +00:00
Devang Patel
9e8ee9242f Use absolute label for DW_AT_stmt_list if a target does not prefer offset here.
This patch was developed on top of original patch by Artur Pietrek.

llvm-svn: 112678
2010-08-31 23:50:19 +00:00
Kevin Enderby
cc1c9257f6 This is the second of three patches to implement support for the .loc directive
and output the dwarf line number tables.  This takes the current loc info after
an instruction is assembled and saves the needed info into an object that has
vector and for each section.  These objects will be used for the final patch to 
build and emit the encoded dwarf line number tables.  Again for now this is only
in the Mach-O streamer but at some point will move to a more generic place.

llvm-svn: 112668
2010-08-31 22:55:11 +00:00
Benjamin Kramer
3f8b8c1f5b Allow creation of SHT_NULL sections, from Roman Divacky.
llvm-svn: 112605
2010-08-31 17:03:33 +00:00
Benjamin Kramer
6c5076f317 MCELF: The value of all common symbols is the offset from the start of the section. Patch by Roman Divacky.
llvm-svn: 112492
2010-08-30 17:20:17 +00:00
Benjamin Kramer
b540b09a7c The value is offset from the start of the section for non-common symbols, submitted by Jordan Gordeev.
llvm-svn: 112473
2010-08-30 12:00:16 +00:00
Benjamin Kramer
ca65cc9222 Index external symbols by symbol table instead of parent section, by Roman Divacky.
llvm-svn: 112472
2010-08-30 11:59:29 +00:00
Benjamin Kramer
3aabb3eb53 Mark all common symbols external. This is not exactly correct but it lets apps
link for now and can be adjusted later. Patch by Roman Divacky.

llvm-svn: 112471
2010-08-30 11:56:55 +00:00
Chris Lattner
b2dbdbc795 squish dead code.
llvm-svn: 112350
2010-08-28 03:21:03 +00:00
Benjamin Kramer
f5c811611e MCELF: Port EmitInstruction changes from MachO streamer. Patch by Roman Divacky.
llvm-svn: 112260
2010-08-27 10:40:51 +00:00
Benjamin Kramer
4e04c2e69f MCELF: Always overwrite FixedValue.
llvm-svn: 112259
2010-08-27 10:38:39 +00:00
Benjamin Kramer
537450a5e8 MCELF: Fix a thinko of mine.
llvm-svn: 112203
2010-08-26 18:12:04 +00:00
Benjamin Kramer
a1f93ec939 MCELF: Compensate for the addend on i386. Patch by Roman Divacky, with some cleanups.
llvm-svn: 112197
2010-08-26 17:23:02 +00:00
Benjamin Kramer
ebee78319c MCELF: Use precomputed symbol indices, patch by Roman Divacky.
llvm-svn: 112079
2010-08-25 20:09:43 +00:00
Michael J. Spencer
052ffacb48 MC: Fix inconsistant naming in COFF object writer. Patch by Cameron Esfahani.
llvm-svn: 112076
2010-08-25 19:27:27 +00:00
Kevin Enderby
bb121d1dc2 Change the parsing of .loc back to allow the LineNumber field to be optional as
it is with other assemblers.

llvm-svn: 111967
2010-08-24 21:14:47 +00:00
Michael J. Spencer
526e183800 Fix COFF x86-64 relocations. PR7960.
Multiple symbol reloc handling part of the patch by Cameron Esfahani.

llvm-svn: 111963
2010-08-24 21:04:52 +00:00
Kevin Enderby
024b04ad93 First bit of support for the dwarf .loc directive. This patch updates the
needed parsing for the .loc directive and saves the current info from that
into the context.  The next patch will take the current loc info after an
instruction is assembled and save that info into a vector for each section for
use to build the line number tables.  The patch after that will encode the info
from those vectors into the output file as the dwarf line tables.

llvm-svn: 111956
2010-08-24 20:32:42 +00:00
Daniel Dunbar
bd6901864b MC/AsmParser: Change ParseExpression to use ParseIdentifier(), to support
dollars in identifiers.

llvm-svn: 111946
2010-08-24 19:13:42 +00:00
Daniel Dunbar
7859dfd71b MC/Parser: Accept leading dollar signs in identifiers.
- Implemented by manually splicing the tokens. If this turns out to be
   problematically platform specific, a more elegant solution would be to
   implement some context dependent lexing support.

llvm-svn: 111934
2010-08-24 18:12:12 +00:00
Benjamin Kramer
958ba693b5 Relocate against parent if the symbol is not in section or it's a common symbol, from Roman Divacky.
llvm-svn: 111925
2010-08-24 17:34:39 +00:00
Chris Lattner
115fdde871 fix rdar://7997827 - Accept and ignore LL and ULL suffixes on integer literals.
Also fix 0b010 syntax to actually work while we're at it :-)

llvm-svn: 111876
2010-08-24 00:43:25 +00:00
Benjamin Kramer
b08a868783 Fix thinko. Having no tests is great ...
llvm-svn: 111848
2010-08-23 21:32:00 +00:00
Benjamin Kramer
005c0b532e Reduce code duplication.
llvm-svn: 111846
2010-08-23 21:23:52 +00:00
Benjamin Kramer
8961d86d95 ELFObjectWriter: Run ComputeSymbolTable before recording relocations. This way we can use the information it has computed and don't have to recompute the same stuff over and over again.
llvm-svn: 111844
2010-08-23 21:19:37 +00:00
Benjamin Kramer
be1f37f512 Add the symbol offset to the relocation value when we relocate against section. By Roman Divacky.
llvm-svn: 111824
2010-08-23 19:05:46 +00:00
Benjamin Kramer
c67b87ec44 Use the proper relocation section + cleanup, from Roman Divacky.
llvm-svn: 111819
2010-08-23 18:24:20 +00:00
Michael J. Spencer
82f1603fa7 Revert part of my last commit. the mingw32 build bot doesn't seem to like it.
llvm-svn: 111793
2010-08-23 05:25:23 +00:00
Michael J. Spencer
c52ac23659 Workaround broken jump tables on x86-64 COFF.
llvm-svn: 111792
2010-08-23 04:45:37 +00:00
Michael J. Spencer
18689045ce MC: Add partial x86-64 support to COFF.
llvm-svn: 111728
2010-08-21 05:58:13 +00:00
Benjamin Kramer
574b1a27b1 MCELF: Count the section orders properly. Patch by Roman Divacky.
llvm-svn: 111517
2010-08-19 13:44:49 +00:00
Daniel Dunbar
9ced206b3a MC/ELF: Allow null values in virtual sections, ELF doesn't use special
directives for putting contents in .bss, for example.

llvm-svn: 111376
2010-08-18 18:22:37 +00:00
Benjamin Kramer
5756afebba Remove dead code. Fixes a GCC warning.
llvm-svn: 111271
2010-08-17 19:45:05 +00:00
Benjamin Kramer
1e37b165c8 Sketch i386 relocations handling, from Roman Divacky.
Hello world builds & runs now on i386/ELF with -integrated-as.

llvm-svn: 111264
2010-08-17 18:20:28 +00:00
Benjamin Kramer
3bc7de0605 Use the correct entry size for relocation entries, from Roman Divacky.
llvm-svn: 111259
2010-08-17 17:56:13 +00:00
Benjamin Kramer
cc741eccfa Differentiate between RELA and REL relocations, from Roman Divacky.
llvm-svn: 111252
2010-08-17 17:30:07 +00:00
Benjamin Kramer
2bf444b7d4 One baby step towards i386 ELF, from Roman Divacky.
llvm-svn: 111247
2010-08-17 17:02:29 +00:00
Benjamin Kramer
3acf387e2d Try to silence a overeager GCC warning.
llvm-svn: 111214
2010-08-17 00:33:24 +00:00
Benjamin Kramer
41deb334b5 A round of minor cleanups for ELFObjectWriter.
llvm-svn: 111213
2010-08-17 00:00:46 +00:00
Benjamin Kramer
70e0faed21 Silence warnings and simplify code. Eliminate a 32/64 bit portability issue.
llvm-svn: 111201
2010-08-16 23:00:12 +00:00
Eli Friedman
39484fda25 Fixes for generation of ELF relocations. Patch by Roman Divacky.
llvm-svn: 111183
2010-08-16 21:17:09 +00:00
Eli Friedman
d2c0d2d0bb Fix a few warnings in and detabify MCELFStreamer and ELFObjectWriter.
llvm-svn: 111175
2010-08-16 19:15:06 +00:00
Matt Fleming
8183e01389 Add ELF ObjectWriter and Streamer support.
I forgot to add these files in commit 111172.

llvm-svn: 111174
2010-08-16 18:57:57 +00:00
Matt Fleming
e381e308f2 Add ELF ObjectWriter and Streamer support.
llvm-svn: 111172
2010-08-16 18:35:43 +00:00
Matt Fleming
5fc461afc4 Layout helper function.
Introduce a helper method to add a section to the end of a layout. This
will be used by the ELF ObjectWriter code to add the metadata sections
(symbol table, etc) to the end of an object file.

llvm-svn: 111171
2010-08-16 18:35:06 +00:00
Matt Fleming
162726c305 Record a symbol's size which is needed for ELF symbol tables.
llvm-svn: 111170
2010-08-16 18:34:31 +00:00
Chris Lattner
e51188af11 silence a vc2010 warning: " result of 32-bit shift implicitly converted to
64 bits (was 64-bit shift intended?)", pointed out by 'nobled' on llvmdev

llvm-svn: 111148
2010-08-16 16:35:20 +00:00