I thought for a long while that if you wanted to profile GHC itself
then you had to
build a profiled version of HEAD. However, this isn't true.
The easiest way to profile GHC itself is to write a simple GHC API
application and compile that
with profiling. Normal GHC distributions come with profiling versions
of the ghc library so you can use this to profile released versions of
For example, here is a simple program that Andreas created when I
suggested he did this.