[lld] r222026 - [PECOFF] Remove dead code
Rui Ueyama
ruiu at google.com
Fri Nov 14 11:21:06 PST 2014
Author: ruiu
Date: Fri Nov 14 13:21:06 2014
New Revision: 222026
URL: http://llvm.org/viewvc/llvm-project?rev=222026&view=rev
Log:
[PECOFF] Remove dead code
AddressOfEntryPoint is overridden after we layout all atoms (until then,
we don't know the entry point address for obvious reason.)
I believe this code is leftover from very early version of the
PE/COFF port that we only had an entry function in a test object file.
Modified:
lld/trunk/lib/ReaderWriter/PECOFF/WriterPECOFF.cpp
Modified: lld/trunk/lib/ReaderWriter/PECOFF/WriterPECOFF.cpp
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/lib/ReaderWriter/PECOFF/WriterPECOFF.cpp?rev=222026&r1=222025&r2=222026&view=diff
==============================================================================
--- lld/trunk/lib/ReaderWriter/PECOFF/WriterPECOFF.cpp (original)
+++ lld/trunk/lib/ReaderWriter/PECOFF/WriterPECOFF.cpp Fri Nov 14 13:21:06 2014
@@ -399,10 +399,6 @@ PEHeaderChunk<PEHeader>::PEHeaderChunk(c
_peHeader.Magic = ctx.is64Bit() ? llvm::COFF::PE32Header::PE32_PLUS
: llvm::COFF::PE32Header::PE32;
- // The address of entry point relative to ImageBase. Windows executable
- // usually starts at address 0x401000.
- _peHeader.AddressOfEntryPoint = 0x1000;
-
// The address of the executable when loaded into memory. The default for
// DLLs is 0x10000000. The default for executables is 0x400000.
_peHeader.ImageBase = ctx.getBaseAddress();
More information about the llvm-commits
mailing list