Building libraries with ticky-ticky
ahunter at cs.hmc.edu
Mon Jul 21 02:35:21 EDT 2008
On Sun, Jul 20, 2008 at 09:08:58PM -0700, Tim Chevalier wrote:
> I'm not surprised that building the libraries with ticky enabled
> doesn't work, because when I fixed ticky-ticky profiling a year and a
> half ago after it was bit-rotted, I hardly tested it and all and
> certainly didn't try building the ticky libraries.
I'm not surprised to see this answer--looking at tickets and mailing lists, it was clear that ticky-ticky wasn't in the best of shape, but I couldn't figure out what exactly the state of affairs was, so I figured I'd ask.
> The reason you got linker errors was because, I assume, you had
> compiled the libraries with -ticky but you weren't passing the -ticky
> flag to GHC when you compiled your program. If you don't pass the
> -ticky flag, GHC doesn't link with the ticky RTS, so the library code
> will include all sorts of undefined symbols.
Right--thing is, it seemed I was getting linker errors on compiling
the *libraries*--which seems weird, given that the libraries shouldn't
be getting linked, should they? I'm not entirely sure this is what I
was seeing, so, well, not a huge consideration, but it does seem
> But since you said below that it's OK if things are broken for
> non-ticky use, you should just be able to do:
> $ cd libraries/
> $ make clean
> $ make EXTRA_HC_OPTS=-ticky
> $ cd [wherever]
> $ ghc -o foo -ticky foo.hs
> $ ./foo +RTS -rfoo.ticky -RTS
> and foo.ticky will contain your profiling report. You just won't be
> able to compile any programs without -ticky this way.
After removing "p" from GhcLibWays, which makes sense--the docs make
it clear we can't combine prof and ticky, though it also implies that
it maybe *should* work; might someone what to look into this?--this
worked great, thanks. My tests are running nicely and giving what
seems like accurate data. Thanks for the very helpful response.
> In the meantime, I'll look into making the "ticky" way work so that
> it'll be possible to have ticky and non-ticky libraries coexisting.
Sweet. Admittedly I'm not yet a GHC wizard, but I'd love to help out
by fixing this--do you have a rough idea of what would need to be
done, or what in fact is the current problem?
Thanks a lot,
More information about the Glasgow-haskell-users