NAKAMURA Takumi
4162034bb5
[CMake] Apply llvm_update_compile_flags() in add_lld_library().
...
Sorry for the breakage.
llvm-svn: 200306
2014-01-28 10:45:37 +00:00
Rui Ueyama
4aaba3e220
[PECOFF] Replace magic numbers with sizeof.
...
llvm-svn: 200278
2014-01-28 01:55:37 +00:00
Rui Ueyama
bdc2fc3635
[PECOFF] Convert more binary files to YAML.
...
Because the object files are now readable to humans, I don't think we need the
source assembly file any more, so I removed them too in this commit.
llvm-svn: 200276
2014-01-28 01:41:39 +00:00
Rui Ueyama
6d3fee23e3
[PECOFF] Remove a redundant test.
...
peplus.test and pe32plus.test basically covered the same thing, so
remove pe32plus.test and then rename peplus.test -> pe32plus.test.
llvm-svn: 200275
2014-01-28 01:36:13 +00:00
Rui Ueyama
dc2f00eead
[PECOFF] Convert a object file to YAML to remove a binary file from SVN.
...
llvm-svn: 200274
2014-01-28 01:32:33 +00:00
Rui Ueyama
a709af2861
s/0/nullptr/
...
llvm-svn: 200272
2014-01-28 01:22:23 +00:00
Rui Ueyama
22291d2cbf
[PECOFF] Implement some relocations for x86-64.
...
llvm-svn: 200240
2014-01-27 19:23:12 +00:00
Rui Ueyama
b73d28525a
[PECOFF] Implement relocations for x86-64.
...
llvm-svn: 200185
2014-01-27 03:53:30 +00:00
Rui Ueyama
7d1bf45047
[PECOFF] Fix PE/COFF optional header size for PE32+.
...
The optional header for PE32+ is a bit larger than PE32 because some of
its fields are extended to 8 bytes.
llvm-svn: 200184
2014-01-27 03:53:26 +00:00
Rui Ueyama
f1a2d55e2b
[PECOFF] Set a proper architecture type to references.
...
Relocations for x64 object files should have reference type of
KindArch::x86_64.
llvm-svn: 200183
2014-01-27 03:53:23 +00:00
Shankar Easwaran
3d8de47f76
Fix trailing whitespace.
...
llvm-svn: 200182
2014-01-27 03:09:26 +00:00
Shankar Easwaran
a64ba010f0
[ELF] Fix comments.
...
The comments in the files that described the file name as part of each file
header ran over 80 columns, which clang-format split over multiple lines.
This commit fixes to make them appear properly.
llvm-svn: 200181
2014-01-27 02:55:08 +00:00
Shankar Easwaran
b11964707c
[ELF] Make changes to all the targets supported currently
...
X86_64,X86,PPC,Hexagon,Mips
No change in functionality.
llvm-svn: 200177
2014-01-27 01:21:02 +00:00
Shankar Easwaran
af7fbd8cf4
[ELF] Create Target specific Writers.
...
llvm-svn: 200176
2014-01-27 01:20:53 +00:00
Shankar Easwaran
e7b831ad35
[ELF] Add Target specific Readers.
...
No change in functionality.
llvm-svn: 200175
2014-01-27 01:02:03 +00:00
Shankar Easwaran
d7de108cde
[ELF] Separate ELFReader classes for subclassing
...
llvm-svn: 200173
2014-01-27 00:45:57 +00:00
Shankar Easwaran
f755ca1685
[ELF] Unify interfaces between DynamicFile/ELFFile.
...
llvm-svn: 200172
2014-01-27 00:40:49 +00:00
Shankar Easwaran
f3db51d06f
[ELF] Separate implementation from the class declaration.
...
ELFFile would be a class that rest of the targets would derive from.
To keep the implementation clean, separate the implementation from
rest of the Header file.
llvm-svn: 200168
2014-01-26 23:57:20 +00:00
Shankar Easwaran
9691b01905
[ELF] Rename File.h to ELFFile.h to avoid confusion.
...
No change in functionality.
llvm-svn: 200166
2014-01-26 23:49:07 +00:00
Shankar Easwaran
b888433e9c
[ELF] Dont include all targets
...
llvm-svn: 200165
2014-01-26 23:47:18 +00:00
Rui Ueyama
56c4611340
[PECOFF] Emit PE32+ file header.
...
llvm-svn: 200128
2014-01-26 05:34:12 +00:00
Rui Ueyama
c6ddf5654c
[PECOFF] Use a shorter name for the parameter.
...
llvm-svn: 200107
2014-01-26 00:37:30 +00:00
Rui Ueyama
76c1b4d0fb
[PECOFF] Set PE32+ magic value if 64 bit.
...
llvm-svn: 200106
2014-01-26 00:35:23 +00:00
Rui Ueyama
7dc69287c1
[PECOFF] Use a shorter name for the PECOFF writer member.
...
llvm-svn: 200052
2014-01-25 00:27:44 +00:00
Rui Ueyama
49bfd5032d
[PECOFF] Accept /machine:x64 option.
...
This is the first patch to support PE32+ format, which is the image format
to use 64 bit address space on Windows/x86-64.
llvm-svn: 200029
2014-01-24 19:17:05 +00:00
Rui Ueyama
87e15c7585
[PECOFF] Use constant instead of magic number.
...
llvm-svn: 200019
2014-01-24 18:03:14 +00:00
Simon Atanasyan
d8cadd6f17
[ELF] Customize a relocation table output format (rel / rela).
...
Add new virtual virtual function `isRelaOutputFormat` to the
`ELFLinkingContext` class. Call this function everywhere we need to
select a relocation table format.
Patch reviewed by Shankar Easwaran and Rui Ueyama.
llvm-svn: 199973
2014-01-24 05:21:21 +00:00
Rafael Espindola
6ba68f10c4
Update for llvm api change.
...
llvm-svn: 199777
2014-01-22 00:14:56 +00:00
Rafael Espindola
79e2d936fd
Update for llvm api change.
...
llvm-svn: 199752
2014-01-21 16:09:55 +00:00
Simon Atanasyan
eafb76ee9b
[Mips] Specify the type of a symbol table entries in the test assembler
...
file.
llvm-svn: 199561
2014-01-18 21:13:05 +00:00
Simon Atanasyan
9dec22dbe2
[Mips] Use explicit assembler instructions in the tests.
...
llvm-svn: 199556
2014-01-18 16:59:19 +00:00
Simon Atanasyan
2f1d6366e7
[Mips] Emit ELF header for MIPS target. ELF flags set is mostly hardcoded.
...
Later we need to improve that solution and build a correct set of flags
by merging ELF flags from all input objects.
llvm-svn: 199555
2014-01-18 16:59:11 +00:00
Simon Atanasyan
0e57a77072
[Mips] Simplify calculations of relocations - replace scatterBits calls
...
by bitwise AND operator and remove redundant local variables.
llvm-svn: 199554
2014-01-18 16:59:00 +00:00
Rui Ueyama
8d7a6f2898
Fix odd titlecasing and spacing in an error message.
...
llvm-svn: 199530
2014-01-18 00:57:40 +00:00
Rui Ueyama
251e68b6ae
Use auto for readability. No functionality change.
...
llvm-svn: 199527
2014-01-18 00:38:44 +00:00
Rui Ueyama
d9696cbda8
Using "final" as a variable name is a bit confusing in C++11, so rename it.
...
llvm-svn: 199526
2014-01-18 00:27:03 +00:00
Simon Atanasyan
9ab3b8db84
[Mips] Allocate local GOT entry for a global symbol defined in an
...
executable file.
llvm-svn: 199517
2014-01-17 21:18:45 +00:00
Simon Atanasyan
362bdc125e
[Mips] Implement .plt and .got.plt section creation.
...
llvm-svn: 199516
2014-01-17 21:18:37 +00:00
Simon Atanasyan
66338224be
[Mips] Handle R_MIPS_26 relocation. Maintaining of .plt and .got.plt
...
sections will be implemented later.
llvm-svn: 199515
2014-01-17 21:18:26 +00:00
Simon Atanasyan
80b86a43d5
[Mips] Provide default name of MIPS-specific interpreter.
...
llvm-svn: 199514
2014-01-17 21:18:14 +00:00
Rui Ueyama
acc795383b
[PECOFF] Tests for DLL name in the export table.
...
llvm-svn: 199428
2014-01-16 21:31:27 +00:00
Rui Ueyama
1792ebc1ab
Relax the expected output so that the tests become robust against llvm-objdump format change.
...
llvm-svn: 199421
2014-01-16 20:41:16 +00:00
Rui Ueyama
2b75630b3b
[PECOFF] Make export table tests readable.
...
llvm-svn: 199409
2014-01-16 18:57:22 +00:00
Rafael Espindola
0de92d53a1
Update for llvm api change.
...
llvm-svn: 199327
2014-01-15 19:38:01 +00:00
Rui Ueyama
4dcc4637b5
[CMake] Add llvm-mc to the list of test dependencies.
...
llvm-svn: 199274
2014-01-14 23:33:04 +00:00
Joey Gouly
010b37691d
[MachO] Begin support for reading fat binaries.
...
llvm-svn: 199259
2014-01-14 22:32:38 +00:00
Simon Atanasyan
13c5ce53dc
[Mips] Do not forget to initialize a class field.
...
llvm-svn: 199241
2014-01-14 18:20:07 +00:00
Simon Atanasyan
e46e2dfe01
[Mips] Calculate gp value only once.
...
llvm-svn: 199240
2014-01-14 18:20:00 +00:00
Simon Atanasyan
db2e1f35d8
[Mips] Create and initialize _gp symbol.
...
llvm-svn: 199239
2014-01-14 18:19:52 +00:00
Simon Atanasyan
3b1a761374
[Mips] Check initialization of _gp_disp and _GLOBAL_OFFSET_TABLE_
...
symbols in case of executable file linking.
llvm-svn: 199238
2014-01-14 18:19:42 +00:00