cvs commit: fptools configure.ac fptools/ghc/compiler/cmm
CLabel.hs fptools/ghc/compiler/nativeGen AsmCodeGen.lhs PprMach.hs
fptools/ghc/driver/mangler ghc-asm.lprl fptools/ghc/rts StgCRun.c
Wolfgang Thaller
wolfgang at haskell.org
Sun Jan 23 01:10:26 EST 2005
wolfgang 2005/01/22 22:10:25 PST
Modified files:
. configure.ac
ghc/compiler/cmm CLabel.hs
ghc/compiler/nativeGen AsmCodeGen.lhs PprMach.hs
ghc/driver/mangler ghc-asm.lprl
ghc/rts StgCRun.c
Log:
Add support for the dead code stripping feature of recent Apple linkers.
If your code is compiled using the NCG, you can now specify
-optl-W,-dead_strip on the GHC command line when linking.
It will have basically the same effect as using split-objs to build the
libraries.
Advantages over split-objs:
* No evil perl script involved
* Requires no special handling when building libraries
Disadvantages:
* The current version of Apple's linker is slow when given the
-dead_strip flag. _REALLY_ slow.
* Mac OS X only.
This works by making the NCG emit the .subsections_via_symbols directive.
Additionally, we have to add an extra label at the top of every info table,
and make sure that the entry code references it (otherwise the info table
will be considered part of the preceding entry code).
The mangler just removes the .subsections_via_symbols directive.
Revision Changes Path
1.104 +16 -0 fptools/configure.ac
1.13 +10 -0 fptools/ghc/compiler/cmm/CLabel.hs
1.66 +8 -1 fptools/ghc/compiler/nativeGen/AsmCodeGen.lhs
1.6 +26 -3 fptools/ghc/compiler/nativeGen/PprMach.hs
1.120 +6 -1 fptools/ghc/driver/mangler/ghc-asm.lprl
1.48 +5 -0 fptools/ghc/rts/StgCRun.c
More information about the Cvs-ghc
mailing list