bug-binutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Bug ld/11539] ld --gc-sections should work for PE-COFF on MinGW


From: sourceware at jf dot hanne.name
Subject: [Bug ld/11539] ld --gc-sections should work for PE-COFF on MinGW
Date: Sat, 12 Mar 2011 14:22:19 +0000

http://sourceware.org/bugzilla/show_bug.cgi?id=11539

--- Comment #1 from sourceware at jf dot hanne.name 2011-03-12 14:21:54 UTC ---
Created attachment 5301
  --> http://sourceware.org/bugzilla/attachment.cgi?id=5301
implement --gc-sections for coff (first shot)

- Mostly a copy and paste from elflink.c to cofflink.c
- This is only a first try; however, it reduces the size of a statically
compiled wxWidgets app from 5.1 MB to 3.8 MB, so it does something useful for
me; YMMV
- I’m by far no COFF export; some linker guru will need to review the patch and
comment on all the "FIXME" comments
- I have not yet tried to generate a DLL with gc enabled
- Somehow the entry symbol does not get into _bfd_coff_gc_keep so no gc mark
root is available; as a workaround, "-Wl,--undefined=_WinMainCRTStartup" should
be used

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]