| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
| |
No functional changes.
llvm-svn: 238310
|
|
|
|
| |
llvm-svn: 238030
|
|
|
|
|
|
|
| |
All instances of the `createImplicitFiles` always return `true` and this
return value is used nowhere.
llvm-svn: 234205
|
|
|
|
|
|
| |
getMergeReginfoMask => getMergedReginfoMask
llvm-svn: 234116
|
|
|
|
|
|
|
|
| |
In case of MIPS N64 ABI linker should merge registers usage masks stored
in the input .MIPS.options sections and save result into the output
.MIPS.options section.
llvm-svn: 234115
|
|
|
|
|
|
|
|
|
|
|
| |
In case of MIPS O32 ABI linker should merge registers usage masks stored
in the input .reginfo sections and save result into the output .reginfo
section.
The ABI states that the .reginfo section should be put into the separate
segment. This requirement is not implemented in this patch.
llvm-svn: 234103
|
|
|
|
|
|
| |
No functional changes.
llvm-svn: 233924
|
|
|
|
|
|
| |
No functional changes.
llvm-svn: 233812
|
|
|
|
|
|
| |
No functional changes.
llvm-svn: 233616
|
|
|
|
| |
llvm-svn: 233344
|
|
|
|
|
|
| |
We dropped Visual Studio 2012 support, so we can use template aliases.
llvm-svn: 231756
|
|
|
|
|
|
|
|
| |
the class field declarations.
No functional changes.
llvm-svn: 227047
|
|
|
|
|
|
| |
No functional changes.
llvm-svn: 226256
|
|
|
|
|
|
|
| |
That reduce class dependencies and simplify the code a bit.
No functional changes.
llvm-svn: 226255
|
|
|
|
| |
llvm-svn: 224813
|
|
|
|
|
|
|
| |
To find an AtomLayout object for the given symbol I replace the
`Layout::findAtomAddrByName` method by `Layout::findAtomLayoutByName` method.
llvm-svn: 223359
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
MIPS ELF symbols might contain some additional MIPS-specific flags
in the st_other field besides visibility ones. These flags indicate
code properties like microMIPS / MIPS16 encoding, position independent
code etc. We need to transfer the flags from input objects to the
output linked file to write them into the symbol table, adjust symbols
addresses etc.
I add new attribute CodeModel to the DefinedAtom class to hold target
specific flag and to get over YAML/Native format conversion barrier.
Other architectures/targets can extend CodeModel enumeration by their
own flags.
MIPS specific part of this patch adds support for STO_MIPS_MICROMIPS
flag. This flag marks microMIPS symbols. Such symbol should:
a) Has STO_MIPS_MICROMIPS in the corresponding .symtab record.
b) Has adjusted (odd) address in the corresponding .symtab
and .dynsym records.
llvm-svn: 221864
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
1. The path checks ELF header flags to prevent linking of incompatible files.
For example we do not allow to link files with different ABI, -mnan
flags, some combination of target CPU etc.
2. The patch merge ELF header flags from input object files to put their
combination to the generated file. For example, if some input files
have EF_MIPS_NOREORDER flag we need to put this flag to the output
file header.
I use the `parseFile()` (not `canParse()`) method because in case of
recognition of incorrect input flags combination we should show detailed
error message and stop the linking process and should not try to use
another `Reader`.
llvm-svn: 221439
|
|
|
|
| |
llvm-svn: 221165
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
When committed in r219353, this patch originally caused problems because it was
not tested in debug build. In such scenarios, Driver.cpp adds two additional
passes. These passes serialize all atoms via YAML and reads it back. Since the
patch changed ObjectAtom to hold a new reference, the serialization was removing
the extra data.
This commit implements r219853 in another way, similar to the original MIPS way,
by using a StringSet that holds the names of all copied atoms instead of
directly holding a reference to the copied atom. In this way, this commit is
simpler and eliminate the necessity of changing the DefinedAtom hierarchy to
hold a new data.
Reviewers: shankarke
http://reviews.llvm.org/D5713
llvm-svn: 219449
|
|
|
|
|
|
| |
This reverts commit r219353 because that seems to break buildbots.
llvm-svn: 219369
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Enhances the creation of an ELF dynamic executable by avoiding recording
unnecessary shared libraries as NEEDED to load a program.
To do this, we must keep track of not only symbols that were referenced but
also of COPY relocations, which steal the symbol from a shared library but does
not store from which lib this symbol came from. To fix this, this commit changes
ObjectSymbol to store the original library from which this symbol came. With
this information, we are able to build a list of the exact shared libraries that
must be marked as DT_NEEDED, instead of blindly marking all shared libraries as
needed.
This logic originally came from the MIPS backend with some adaptation.
Reviewers: atanasyan, shankar.easwaran
http://reviews.llvm.org/D5574
llvm-svn: 219353
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This commit implements in the X86_64 ELF lld backend yet another feature that
was only available in the MIPS backend. However, this patch changes generic ELF
classes to make it trivial for other ELF backends to use this logic too. When
creating a dynamic executable that has dynamic relocations against weak
undefined symbols, these symbols must be exported to the dynamic symbol table
to seek a possible resolution at run time.
A common use case is the __gmon_start__ weak glibc undefined symbol.
Reviewer: shankarke
http://reviews.llvm.org/D5571
llvm-svn: 219349
|
|
|
|
|
|
| |
This reverts commit e137dd93e1291a2d2fa7f41c8f8bcdb59c8b3225.
llvm-svn: 219313
|
|
|
|
| |
llvm-svn: 219278
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary: With r218633, the logic that monitors which shared library symbols were used was copied from the MIPS lld backend to ELF classes, making it available to all ELF backends. However, this made the isDynSymEntryRequired() functions in MipsDynamicLibraryWriter.h/MipsELFWriters.h/MipsExecutableWriter.h to be duplicated logic, since this is already implemented in OutputELFWriter<>/DefaultLayout. This patch removes this duplicated code from MIPS.
Reviewers: Bigcheese, shankarke
Reviewed By: shankarke
Subscribers: llvm-commits
Differential Revision: http://reviews.llvm.org/D5564
llvm-svn: 218846
|
|
|
|
|
|
| |
No functional changes.
llvm-svn: 213310
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
dynamic symbol table populating and DT_NEEDED tag creation.
The `isDynSymEntryRequired` function returns true if the specified shared
library atom requires a dynamic symbol table entry. The `isNeededTagRequired`
function returns true if we need to create DT_NEEDED tag for the shared
library defined specified shared atom.
By default the both functions return true. So there is no functional changes
for all targets except MIPS. Probably we need to spread the same modifications
on other ELF targets but I want to implement and fully tested complete set of
changes for MIPS target first.
For MIPS we create a dynamic symbol table entry for a shared library atom iif
this atom is referenced by a regular defined atom. For example, if library L1
defines symbol T1, library L2 defines symbol T2 and uses symbol T1
and executable file E1 uses symbol T2 but does not use symbol T1 we create
an entry in the E1 dynamic symbol table for symbol T2 and do not create
an entry for T1.
The patch creates DT_NEEDED tags for shared libraries contain shared library
atoms which a) referenced by regular defined atoms; b) have corresponding
copy dynamic relocations (R_MIPS_COPY).
Now the patch does not take in account --as-needed / --no-as-needed command
line options. So it is too restrictive and create DT_NEEDED tags for really
needed shared libraries only. I plan to fix that by subsequent patches.
llvm-svn: 211674
|
|
|
|
| |
llvm-svn: 210831
|
|
|
|
|
|
| |
R_MIPS_TLS_LDM etc.
llvm-svn: 210394
|
|
|
|
|
|
|
| |
There is no std::error_code::success, so this removes much of the noise
in transitioning to std::error_code.
llvm-svn: 209948
|
|
|
|
|
|
| |
the MipsELFWriters member function.
llvm-svn: 209592
|
|
|
|
| |
llvm-svn: 207435
|
|
|
|
|
|
| |
from MipsELFWriter class. MipsELFWriter is just a helper.
llvm-svn: 203402
|
|
|
|
|
|
| |
where it is appropriate.
llvm-svn: 203102
|
|
|
|
|
|
|
| |
undefined symbols to '.dynsym' if these symbols have corresponding entries
in a global part of GOT.
llvm-svn: 200716
|
|
|
|
| |
llvm-svn: 200715
|
|
|
|
| |
llvm-svn: 200328
|
|
X86_64,X86,PPC,Hexagon,Mips
No change in functionality.
llvm-svn: 200177
|