[Webkit-unassigned] [Bug 102827] [CMake] Optimize binary size by removing dead sections on unix/gcc

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Tue Nov 20 13:03:36 PST 2012


https://bugs.webkit.org/show_bug.cgi?id=102827





--- Comment #3 from Raphael Kubo da Costa (rakuco) <rakuco at webkit.org>  2012-11-20 13:05:34 PST ---
(From update of attachment 175257)
View in context: https://bugs.webkit.org/attachment.cgi?id=175257&action=review

With regard to the compiler flags, gcc's man page says:

           Only use these options when there are significant benefits from
           doing so.  When you specify these options, the assembler and linker
           will create larger object and executable files and will also be
           slower.  You will not be able to use "gprof" on all systems if you
           specify this option and you may have problems with debugging if you
           specify both this option and -g.

This sounds quite alarming; what if you just change the linker flags? Is there much difference if you compare gold and ld?

With my packager hat on, when a program uses unusual compiler or linker flags by default it tends to trigger my spider-sense; is there any trade-off we're not aware of when enabling these flags?

> Source/cmake/OptionsCommon.cmake:37
> +IF (CMAKE_COMPILER_IS_GNUCC AND UNIX AND NOT APPLE)

This is similar to the check we have in the WEBKIT_SET_EXTRA_COMPILER_FLAGS macro, so I wonder why this was not just put there.

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.


More information about the webkit-unassigned mailing list