[wx-dev] usefulness of precompiled headers
Milan Babuskov
milanb at panonnet.net
Thu Nov 29 06:36:02 PST 2007
Ryan Hill wrote:
> We had a user request recently that --enable-precomp-headers be configurable
> to help people short on disk space or memory to build wxGTK at the expense of
> compile time. While examining the effects disabling PCH would have I found
> some surprising results. In all tests disabling PCH not only cut disk
> requirements by 66-75%, but also shrank compile times by ~33%. I tested on a
> couple different machines with several different GCC versions to see if I
> could find a situation where enabling PCH is beneficial but the results were
> more or less consistent. If this is the case then I wonder if the default
> should be reconsidered. Do other compilers or environments make PCH a win?
It all depends on the amount of RAM your system has.
My laptop with 128MB is very slow with PCH, and much better with PCH
disabled. My other machine with 512MB RAM is much faster with PCH.
--
Milan Babuskov
http://www.flamerobin.org
More information about the wx-dev
mailing list