Decoupling -O from -fvia-C
Wolfgang Thaller <[email protected]>
| Newsgroups | gmane.comp.lang.haskell.cvs.all,gmane.comp.lang.haskell.cvs.ghc |
|---|---|
| Message-ID | <[email protected]> |
I think it is again time to discuss whether -O should still imply - fvia-C. I have recently committed a few patches that allow the NCG to compile the RTS. Position-independent code works in the NCG on Darwin/x86 and (almost untested) on Linux/x86, but will never work in for -fvia-C compilation. So now there are situations where -fasm is required, and there are fewer and fewer situations where -fvia-C is required. The Makefile in compiler/ adds -O to the HC_OPTS for some files, which overrides any global -fasm, so compiling a libHSghc_dyn.dylib (or .so) requires editing the Makefile. The only argument for having -O imply -fvia-C that I am aware of is that -fvia-C code is slightly faster than -fasm on x86. This was not even the case on PowerPC, last time I checked. I rest my case. Cheers, Wolfgang