forked from OSchip/llvm-project
![]() ICF is a feature to merge sections not by name (which is the regular COMDAT merging) but by contents. If two or more sections have the identical contents and relocations, ICF merges them to save space. Accessors or templated functions tend to have the same contents, and ICF can hold them. If we consider sections as vertices and relocations as edges, the problem is to find as many isomorphic graphs as possile from input graphs. MSVC linker is smart enough to identify isomorphic graphs even if they contain circles (GNU gold cannot handle circles according to http://research.google.com/pubs/pub36912.html, so this is impressive). Circular references are not uncommon in COFF object files. One example is .pdata. .pdata sections contain exception handler info for functions, so they naturally have relocations for the functions. The functions in turn have references to the .pdata sections so that the functions and their .pdata are linked together. As a result, they form circles. This is a test case for circular graphs. LLD is not able to handle this test case yet. I'll add code soon. llvm-svn: 245827 |
||
---|---|---|
.. | ||
COFF | ||
ELF | ||
cmake/modules | ||
docs | ||
include/lld | ||
lib | ||
test | ||
tools | ||
unittests | ||
.arcconfig | ||
.clang-format | ||
.gitignore | ||
CMakeLists.txt | ||
CODE_OWNERS.TXT | ||
LICENSE.TXT | ||
README.md |
README.md
LLVM Linker (lld)
This directory and its subdirectories contain source code for the LLVM Linker, a modular cross platform linker which is built as part of the LLVM compiler infrastructure project.
lld is open source software. You may freely distribute it under the terms of the license agreement found in LICENSE.txt.