llvm-project/lld/COFF
Martin Storsjö df8f3bf626 [LLD] [COFF] Check the aux section definition size for IMAGE_COMDAT_SELECT_SAME_SIZE
Binutils generated sections seem to be padded to a multiple of 16 bytes,
but the aux section definition contains the original, unpadded section
length.

The size check used for IMAGE_COMDAT_SELECT_SAME_SIZE previously
only checked the size of the section itself. When checking the
currently processed object file against the previously chosen
comdat section, we easily have access to the aux section definition
of the currently processed section, but we have to iterate over the
symbols of the previously selected object file to find the section
definition of the previously picked section. (We don't want to
inflate SectionChunk to carry more data, for something that is only
needed in corner cases.) Only do this when the mingw flag is set.

This fixes statically linking clang-built C++ object files against
libstdc++ built with GCC, if the object files contain e.g. typeinfo.

Differential Revision: https://reviews.llvm.org/D86659
2020-08-27 15:08:57 +03:00
..
CMakeLists.txt [COFF] Port CallGraphSort to COFF from ELF 2020-07-30 15:21:44 -07:00
CallGraphSort.cpp [COFF] Port CallGraphSort to COFF from ELF 2020-07-30 15:21:44 -07:00
CallGraphSort.h [COFF] Port CallGraphSort to COFF from ELF 2020-07-30 15:21:44 -07:00
Chunks.cpp [COFF] Migrate COFFObjectFile to Expected<T> 2020-05-08 14:01:39 -07:00
Chunks.h [COFF] Avoid allocating temporary vectors during ICF 2020-05-04 07:01:14 -07:00
Config.h [COFF] Port CallGraphSort to COFF from ELF 2020-07-30 15:21:44 -07:00
DLL.cpp [LLD] [COFF] Fix alignment of thunks for ARM/ARM64 2020-04-13 23:27:15 +03:00
DLL.h [COFF] Share the tail in delayimport symbol thunks 2019-07-11 21:19:11 +00:00
DebugTypes.cpp Make helpers static. NFC. 2020-07-17 13:49:11 +02:00
DebugTypes.h [COFF] Move type merging to TpiSource::mergeDebugT virtual method 2020-05-14 09:47:00 -07:00
Driver.cpp [COFF] Port CallGraphSort to COFF from ELF 2020-07-30 15:21:44 -07:00
Driver.h [COFF] Move type merging to TpiSource::mergeDebugT virtual method 2020-05-14 09:47:00 -07:00
DriverUtils.cpp [COFF] Use a global option table to avoid reconstructing it 2020-05-02 15:04:19 -07:00
ICF.cpp [Support] Move LLD's parallel algorithm wrappers to support 2020-05-05 15:21:05 -07:00
ICF.h [Coding style change][lld] Rename variables for non-ELF ports 2019-07-11 05:40:30 +00:00
InputFiles.cpp [LLD] [COFF] Check the aux section definition size for IMAGE_COMDAT_SELECT_SAME_SIZE 2020-08-27 15:08:57 +03:00
InputFiles.h [LLD] [COFF] Check the aux section definition size for IMAGE_COMDAT_SELECT_SAME_SIZE 2020-08-27 15:08:57 +03:00
LLDMapFile.cpp [Support] Move LLD's parallel algorithm wrappers to support 2020-05-05 15:21:05 -07:00
LLDMapFile.h [lld-link] Support /map option, matching link.exe 's /map output format 2020-03-24 09:48:00 -04:00
LTO.cpp [LTO] Suppress emission of empty combined module by default 2020-05-04 18:31:09 -07:00
LTO.h [COFF] Assign unique identifiers to ObjFiles from LTO 2020-04-17 17:15:12 -07:00
MapFile.cpp [Support] Move LLD's parallel algorithm wrappers to support 2020-05-05 15:21:05 -07:00
MapFile.h [Coding style change][lld] Rename variables for non-ELF ports 2019-07-11 05:40:30 +00:00
MarkLive.cpp [COFF] Don't treat DWARF sections as GC roots 2020-03-27 12:37:43 -07:00
MarkLive.h [Coding style change][lld] Rename variables for non-ELF ports 2019-07-11 05:40:30 +00:00
MinGW.cpp [LLD] [Mingw] Don't export symbols from profile generate 2020-07-30 23:33:20 +03:00
MinGW.h [COFF] Don't include llvm/LTO/LTO.h in a header 2019-11-14 13:47:18 -08:00
Options.td [COFF] Port CallGraphSort to COFF from ELF 2020-07-30 15:21:44 -07:00
PDB.cpp Revert "Re-Re-land: [CodeView] Add full repro to LF_BUILDINFO record" 2020-08-17 15:49:18 -04:00
PDB.h [LLD] [COFF] Wrap file location pair<StringRef,int> in Optional<>. NFC. 2019-10-15 09:18:18 +00:00
README.md
SymbolTable.cpp [LLD][COFF] Skip computation of the undefined symbols references that are not shown 2020-07-20 13:45:16 -04:00
SymbolTable.h [COFF] Assign unique identifiers to ObjFiles from LTO 2020-04-17 17:15:12 -07:00
Symbols.cpp [COFF] Migrate COFFObjectFile to Expected<T> 2020-05-08 14:01:39 -07:00
Symbols.h [COFF] Paritally inline Symbol::getName, NFC 2020-05-03 07:58:05 -07:00
TypeMerger.h [COFF] Move type merging to TpiSource::mergeDebugT virtual method 2020-05-14 09:47:00 -07:00
Writer.cpp [LLD][COFF] Reset outputSections for successive runs 2020-08-22 23:08:43 +03:00
Writer.h [Coding style change][lld] Rename variables for non-ELF ports 2019-07-11 05:40:30 +00:00

README.md

See docs/NewLLD.rst