summaryrefslogtreecommitdiffstats
path: root/lld/lib/Core/SymbolTable.cpp
Commit message (Collapse)AuthorAgeFilesLines
...
* Fix indentation, use early return.Rui Ueyama2013-11-131-121/+115
| | | | llvm-svn: 194619
* [lld][InputGraph] Change the Resolver to use inputGraphShankar Easwaran2013-10-071-1/+0
| | | | | | | | | | | | Changes :- a) Functionality in InputGraph to insert Input elements at any position b) Functionality in the Resolver to use nextFile c) Move the functionality of assigning file ordinals to InputGraph d) Changes all inputs to MemoryBuffers e) Remove LinkerInput, InputFiles, ReaderArchive llvm-svn: 192081
* Add a fallback mechanism for undefined atom.Rui Ueyama2013-09-121-1/+10
| | | | | | | | | | | | | | | | | In COFF, an undefined symbol can have up to one alternative name. If a symbol is resolved by its regular name, then it's linked normally. If a symbol is not found in any input files, all references to the regular name are resolved using the alternative name. If the alternative name is not found, it's a link error. This mechanism is called "weak externals". To support this mechanism, I added a new member function fallback() to undefined atom. If an undefined atom has the second name, fallback() returns a new undefined atom that should be used instead of the original one to resolve undefines. If it does not have the second name, the function returns nullptr. Differential Revision: http://llvm-reviews.chandlerc.com/D1550 llvm-svn: 190625
* Rename TargetInfo -> LinkingContext.Rui Ueyama2013-08-061-5/+5
| | | | | | | | | Also change some local variable names: "ti" -> "context" and "_targetInfo" -> "_context". Differential Revision: http://llvm-reviews.chandlerc.com/D1301 llvm-svn: 187823
* This is my Driver refactoring patch. Nick Kledzik2013-04-041-7/+3
| | | | | | | | | | | | | | | | | | | | | | | The major changes are: 1) LinkerOptions has been merged into TargetInfo 2) LinkerInvocation has been merged into Driver 3) Drivers no longer convert arguments into an intermediate (core) argument list, but instead create a TargetInfo object and call setter methods on it. This is only how in-process linking would work. That is, you can programmatically set up a TargetInfo object which controls the linking. 4) Lots of tweaks to test suite to work with driver changes 5) Add the DarwinDriver 6) I heavily doxygen commented TargetInfo.h Things to do after this patch is committed: a) Consider renaming TargetInfo, given its new roll. b) Consider pulling the list of input files out of TargetInfo. This will enable in-process clients to create one TargetInfo the re-use it with different input file lists. c) Work out a way for Drivers to format the warnings and error done in core linking. llvm-svn: 178776
* [SymbolTable][Perf] Use hash_combine instead of a custom hash, also use memcmp.Michael J. Spencer2013-03-201-14/+9
| | | | | | | | | | ArrayRef<uint8_t>::equals(); lowers to a byte compare loop :(. TODO: Figure out if we are getting hash collisions, or just have a lot of equal content. Also test if crypto hashing the content instead of full compare is better. llvm-svn: 177588
* [lld] remove trailing whitespaceShankar Easwaran2013-03-141-1/+1
| | | | llvm-svn: 177079
* [Core] Only complain about undefined symbols if they are marked as ↵Michael J. Spencer2013-01-311-3/+3
| | | | | | canBeNullNever. llvm-svn: 174107
* [Core] Move Resolver and SymbolTable over to TargetInfo.Michael J. Spencer2013-01-221-7/+10
| | | | | | No functionality change. llvm-svn: 173192
* Add new merge-by-content Merge attribute for use by anonymousNick Kledzik2013-01-151-3/+11
| | | | | | constants and string literals which the linker should coalesce. llvm-svn: 172495
* Style fixes.Michael J. Spencer2013-01-041-9/+0
| | | | llvm-svn: 171531
* Slightly better diagnostics on duplicate symbols.Michael J. Spencer2013-01-041-0/+9
| | | | llvm-svn: 171528
* Major refactoring: Remove Platform concept. In its place there are Nick Kledzik2012-05-311-3/+3
| | | | | | | | now Reader and Writer subclasses for each file format. Each Reader and Writer subclass defines an "options" class which controls how that Reader or Writer operates. llvm-svn: 157774
* Add way to represent static archives in yaml test cases.Nick Kledzik2012-04-201-0/+12
| | | | | | | | | Add SharedLibraryFile and ArchiveLibraryFile subclasses of File. Add command line options to lld-core to set various ResolverOptions settings and added lots of test cases to verify the options work. llvm-svn: 155183
* Factor out core linking options from Platform in a new ResolverOptionsNick Kledzik2012-04-181-14/+41
| | | | | | | | | | class. Change Resolver to no longer use Platform. Core linking now issues errors directly. We need to factor that out later. Rework how Darwin executable writer finds "main" atom. It now adds to core linking an Atom which has a Reference to "main". llvm-svn: 155060
* Remove trailing whitespace.Michael J. Spencer2012-04-031-7/+7
| | | | llvm-svn: 153964
* Steal LLVM.h from Clang. This brings in very commonly used LLVM ADT/SupportMichael J. Spencer2012-04-031-12/+12
| | | | | | types into the lld namespace. llvm-svn: 153963
* Use the LLVM RTTI library.Michael J. Spencer2012-04-021-4/+9
| | | | llvm-svn: 153912
* Replace all uses of NULL with nullptr.Michael J. Spencer2012-03-291-8/+8
| | | | llvm-svn: 153677
* Rearange header order to match llvm style. This exposed some missing types.Michael J. Spencer2012-03-281-7/+7
| | | | | | Also fix some Platform.h includes that somehow got missed last time. llvm-svn: 153590
* Add support for SharedLibraryAtoms (proxy atoms for exported symbols from a Nick Kledzik2012-02-221-6/+50
| | | | | | | | shared library) and AbsoluteAtoms (proxy atoms for absolute address (e.g. ROM)). Redesign weak importing as can-be-null-at-runtime and can-be-null-at-build-time. Add lots of test cases for all the above. llvm-svn: 151204
* use llvm::DenseMap instead of std::mapNick Kledzik2012-02-151-2/+2
| | | | llvm-svn: 150547
* (no commit message)Nick Kledzik2012-02-151-1/+1
| | | | llvm-svn: 150539
* A couple of big refactorings: 1) Move most attributes of Atom down to ↵Nick Kledzik2012-01-111-48/+80
| | | | | | DefinedAtom, so only atoms representing definitions need to implement them. 2) Remove definitionTentative, definitionWeak, mergeDuplicates, and autoHide. Replace with merge and interposable attributes. 3) Make all methods on Atom be virtual so that future object file readers can lazily generated attributes llvm-svn: 147903
* add initial support for coalescing by content (c-strings) with test caseNick Kledzik2012-01-091-1/+55
| | | | llvm-svn: 147799
* Support more Atom attributes. Add more test cases to lld-coreNick Kledzik2012-01-041-19/+27
| | | | llvm-svn: 147571
* Add more merging/coalescing test cases and make core linking work for themNick Kledzik2011-12-221-9/+32
| | | | llvm-svn: 147130
* Refactor and comment Atom attributes. Replace combine() with internalName() ↵Nick Kledzik2011-12-201-14/+14
| | | | | | and mergeDuplicates() llvm-svn: 146958
* Initial commit. Code by Nick Kledzik. Cleanups and build system by me.Michael J. Spencer2011-12-181-0/+140
llvm-svn: 146844
OpenPOWER on IntegriCloud