-mdynamic-no-pic
-mdynamic-no-pic
- Subject: -mdynamic-no-pic
- From: Ben Dougall <email@hidden>
- Date: Wed, 16 Jul 2003 15:12:00 +0100
i'm curious about -mdynamic-no-pic that's talked about in this article:
Mach-O ABI
<
http://www.unsanity.org/archives/000044.php>
in particular:
"the recent [page dated October 21, 2002] update to GCC, the compiler
shipped with OSX, allows it to perform so-called -mdynamic-no-pic
optimization, which hard-codes the data addresses in the code, so the
result is roughly equivalent to the CFM ABI used in Mac OS Classic --
so the GCC itself, compiled with that optimization, is 10% faster.
Applications, to take advantage of that, need to be recompiled, so it
doesn't affect 80% of the titles already shipped for Mac OS X. Then
again, the optimization above only works for executables and not shared
libraries."
is this (especially -mdynamic-no-pic) applicable to cocoa app
compilation? i guess so. hard-coding the data addresses sounds
potentially problematic (clashes of some sort?) to me (i don't have a
clue what i'm talking about though), or maybe a step backwards (less
dynamism in some way)?
from the gcc manual:
-mdynamic-no-pic
On Darwin and Mac OS X systems, compile code so that
it is not relocatable, but that its external refer-
ences are relocatable. The resulting code is suitable
for applications, but not shared libraries. (APPLE
ONLY)
if compiling an app, -mdynamic-no-pic should be used without question
right? and if so why isn't it default? or is it even?
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.