On Tue, Jul 19, 2011 at 6:02 PM, Johan Tibell <johan.tib...@gmail.com> wrote: > I've implemented the primop but run into some difficulty: to use the > above fallback I need the code to be statically linked into every > binary. I'm not quite sure how to achieve that.
If dynamic linking doesn't hurt performance (too much). Could I stick this piece of C code in ghc-prim? Are we guaranteed to always link against ghc-prim? > GCC manages by having > the above function definition in libc, which is always statically > linked. I just realized that this isn't true. I wonder if GCC's __builtin_popcount suffers a performance degradation when libc is dynamically linked. > I think LLVM uses a small statically linked compiler run-time > library for the same purpose. However I believe this is the case still. I'll need to doublecheck. Johan _______________________________________________ Glasgow-haskell-users mailing list Glasgow-haskell-users@haskell.org http://www.haskell.org/mailman/listinfo/glasgow-haskell-users