
Hello Magnus, Saturday, September 27, 2008, 3:48:27 PM, you wrote:
AFAIU you are saying that the linker is reaching into the module's .a file, pulling out the .o file, and then reaching into that .o file to pull out an individual function's ASM code. I believe that's a bit more than regular C linkers would do.
compiled haskell module represented in ghc as a .hi+.o files, installed libraries as a .a plus a set of .h files (you may find lots of .hi in your ghc installation) afaiu, .hi files contains parts f source haskell code in some partially compiled form. ability to perform inter-module and inter-library inlining is a key to efficiency of ghc-compiled programs, specially for polymorphic functions. when you use such functions as head, you are definitely got them inlined -- Best regards, Bulat mailto:Bulat.Ziganshin@gmail.com