How Long Does It Take to Compile Haskell?

I’ve been compiling ghc from MacPorts on this 2.0 GHz MacBook, and I’m beginning to wonder if it’s hung. I’ve been stuck on “Building ghc” for quite a while, maybe an hour:

--->  Cleaning perl5.8
--->  Fetching ghc
--->  Attempting to fetch ghc-6.10.1-src.tar.bz2 from http://haskell.org/ghc/dist/stable/dist/
--->  Attempting to fetch ghc-6.10.1-src-extralibs.tar.bz2 from http://haskell.org/ghc/dist/stable/dist/
--->  Attempting to fetch ghc-6.8.2-darwin-i386-leopard-bootstrap.tar.bz2 from http://haskell.org/ghc/dist/6.8.2/
--->  Verifying checksum(s) for ghc
--->  Extracting ghc
--->  Applying patches to ghc
--->  Configuring ghc
--->  Building ghc

Certainly it was long enough to answer a bunch of e-mails, and edit an article. Is this the point where it actually compiles the compiler? Is ghc self-hosting? That is, is ghc written in ghc? That may be what the bootstrap bit is about. Yep, looks like it is.

I do remember 2 hour gcc compiles, but that was 15 years ago on much slower hardware. How long does it take to compile a compiler nowadays?

One Response to “How Long Does It Take to Compile Haskell?”

  1. modgen Says:

    The whole way that MacPorts recompiles everything makes it take a really, really long time. apt-get on Ubuntu is so much faster.

Leave a Reply