gnustep-dev
[Top][All Lists]
Advanced

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

Re: Header cleanliness [was: removing the 'make install'-->'makeall'depe


From: Markus Hitter
Subject: Re: Header cleanliness [was: removing the 'make install'-->'makeall'dependency]
Date: Tue, 24 Dec 2002 00:58:50 +0100


Am Montag, 23.12.02 um 02:25 Uhr schrieb Nicola Pero:

If we get precompiled headers on GNU, that might become the preferred
solution even to cut down compilation time, because usually you will have a precompiled version of Foundation/Foundation.h and of AppKit/AppKit.h, while you will not have precompiled versions of the specific Foundation/*,
AppKit/* headers if you include them separately.

Why not?

Good point :-)

I don't know enough about precompiled headers to really answer - but I
heard it's that way on Apple. Maybe they were too lazy to precompile all
headers.

From what I've listened in the Apple lists, it seems there is quite some dependancy checking to be done when a precompiled header is read in. Check for predefined definitions, for file modification dates, for equal named files in different places, ...

If you load more than one or two header files, you quickly might waste more time with these checks than you save by the precompilation.

Then, it doesn't hurt to load more than you need as long as it goes quickly.

At last, the precompiled headers aren't that small. Usually several Megs in size.


If somebody wants to try, go to OS X and play with the "fixprecomps" script. Currently it makes a precomp for each of the frequent used Frameworks/Libraries: AppKit.p, ApplicationServices.p, Carbon.p, Cocoa.p, CoreServices.p, Foundation.p, libc.p, mach.p and unistd.p (OK, the last two might be an exception).



Cheers,
Markus


P.S.: I've checked some sizes too. Note the differences between the three where Cocoa.h includes both, AppKit.h and Foundation.h: -rw-r--r-- 1 root wheel 3002704 Sep 30 22:09 /System/Library/Frameworks/Cocoa.framework/Versions/A/Headers/Cocoa- gcc3.p -rw-r--r-- 1 root wheel 2413380 Sep 30 22:08 /System/Library/Frameworks/Foundation.framework/Versions/C/Headers/ Foundation-gcc3.p -rw-r--r-- 1 root wheel 3002556 Sep 30 22:08 /System/Library/Frameworks/AppKit.framework/Versions/C/Headers/AppKit- gcc3.p

- - - - - - - - - - - - - - - - - - -
Dipl. Ing. Markus Hitter
http://www.jump-ing.de/






reply via email to

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