llvm-project/lld/COFF
Martin Storsjo 08ab568aaa [COFF] Do MinGW specific entry/subsystem inference
ld.bfd doesn't do any inference of subsystem; unless the windows
subsystem is specified, the console subsystem is used.

For the console subsystem, the entry point is called mainCRTStartup,
regardless of whether the the user code entry point is main or wmain.
The same goes for the windows subsystem, where the entry point always
is WinMainCRTStartup, for both WinMain and wWinMain in user code.

One detail that we don't emulate, is that if the inferred entry point
is undefined, ld.bfd silently just sets the entry point to the start
of the image. And if an explicit entry point is set, but it is
undefined, the link still succeeds but the linker warns about the
entry point not being found.

Differential Revision: https://reviews.llvm.org/D52931

llvm-svn: 343879
2018-10-05 19:43:24 +00:00
..
CMakeLists.txt Merge {COFF,ELF}/Strings.cpp to Common/Strings.cpp. 2018-02-28 17:38:19 +00:00
Chunks.cpp [LLD][COFF] Fix ordering of CRT global initializers in COMDAT sections 2018-10-05 12:56:46 +00:00
Chunks.h [LLD][COFF] Fix ordering of CRT global initializers in COMDAT sections 2018-10-05 12:56:46 +00:00
Config.h COFF: Add support for /force:multiple option 2018-09-13 22:05:10 +00:00
DLL.cpp [COFF] Support linking to import libraries from GNU binutils 2018-09-21 22:01:06 +00:00
DLL.h [COFF] Support linking to import libraries from GNU binutils 2018-09-21 22:01:06 +00:00
Driver.cpp [COFF] Do MinGW specific entry/subsystem inference 2018-10-05 19:43:24 +00:00
Driver.h lld-link: Fix subsystem inference for non-console apps on 32-bit, and fix entry point inference on 32-bit with /nodefaultlib 2018-08-03 12:00:12 +00:00
DriverUtils.cpp lld-link: Remove /msvclto option 2018-08-01 19:00:49 +00:00
ICF.cpp [COFF] When doing automatic dll imports, replace whole .refptr.<var> chunks with __imp_<var> 2018-08-31 07:45:20 +00:00
ICF.h Consistent use of header file for ICF and MarkLive 2018-02-20 22:09:59 +00:00
InputFiles.cpp [COFF] Cope with GCC produced weak aliases referring to comdat functions 2018-10-05 19:43:16 +00:00
InputFiles.h COFF: Implement safe ICF on rodata using address-significance tables. 2018-08-23 17:44:42 +00:00
LTO.cpp Code cleanup in preparation for adding LTO for wasm. NFC. 2018-05-22 20:20:25 +00:00
LTO.h Code cleanup in preparation for adding LTO for wasm. NFC. 2018-05-22 20:20:25 +00:00
MapFile.cpp [COFF] Add support for creating range extension thunks for ARM 2018-09-25 10:59:29 +00:00
MapFile.h COFF: Change the /lldmap output format to be more like the ELF linker. 2017-01-14 03:14:46 +00:00
MarkLive.cpp [COFF] When doing automatic dll imports, replace whole .refptr.<var> chunks with __imp_<var> 2018-08-31 07:45:20 +00:00
MarkLive.h Consistent use of header file for ICF and MarkLive 2018-02-20 22:09:59 +00:00
MinGW.cpp [COFF] Don't do autoexport of symbols from GNU import libraries 2018-09-26 06:13:47 +00:00
MinGW.h [COFF] Don't do autoexport of symbols from GNU import libraries 2018-09-26 06:13:47 +00:00
Options.td [lld-link] Generalize handling of /debug and /debug:{none,full,fastlink,ghash,symtab} 2018-09-24 15:28:03 +00:00
PDB.cpp [LLD][COFF] Fix pdb loading when the path points to a removable device 2018-09-28 21:53:40 +00:00
PDB.h lld-link: Set PDB GUID to hash of PDB contents instead of to a random byte sequence. 2018-09-15 18:37:22 +00:00
README.md Update the documents of the new LLD. 2016-03-12 06:06:40 +00:00
SymbolTable.cpp [COFF] Allow automatic dllimport from gnu import libraries 2018-09-26 06:13:39 +00:00
SymbolTable.h [COFF] don't mark lazy symbols as used in regular objects 2018-09-06 20:23:56 +00:00
Symbols.cpp [COFF] When doing automatic dll imports, replace whole .refptr.<var> chunks with __imp_<var> 2018-08-31 07:45:20 +00:00
Symbols.h [COFF] Allow automatic dllimport from gnu import libraries 2018-09-26 06:13:39 +00:00
Writer.cpp [LLD][COFF] Fix ordering of CRT global initializers in COMDAT sections 2018-10-05 12:56:46 +00:00
Writer.h [COFF] Add support for creating range extension thunks for ARM 2018-09-25 10:59:29 +00:00

README.md

See docs/NewLLD.rst