Commits on Nov 13, 2009
  1. Use eta-expansion to ensure that INLINE things have their expected arity committed Nov 13, 2009
    See Note [Eta-expanding INLINE things] in DsBinds
    This is to fix a performance bug that Roman was encountering.
  2. The rest of the #1185 patch (forkProcess and -threaded)

    simonmar committed Nov 13, 2009
    Due to darcs confusion, I managed to leave out part of the patch for
    #1185.  This should make 1185(threaded1) go through now.
  3. Make the new ClassOp/DFun selection mechanism work for single-method … committed Nov 13, 2009
    I'd forgotten the case of single-method classes! I've also improved
    the documentation. See
      Note [ClassOp/DFun selection]
      Note [Single-method classes]
    both in TcInstDcls
Commits on Nov 12, 2009
  1. Switch EventThreadID back to 32 bits.

    simonmar committed Nov 12, 2009
    The log file format was still using 32 bits, this just updates the
    header file to match; there should be no functional changes.
  2. Comments only committed Nov 12, 2009
  3. Remove old, redundant note committed Nov 12, 2009
  4. Fix bug when the combined package DB has duplicate package IDs

    simonmar committed Nov 12, 2009
    Someone on IRC reported that they were encountering a strange missing
    module error from GHC, and it turned out that they had mtl-
    installed in both the global and local DB, with the same
    InstalledPackageId.  The two packages should be interchangeable, but
    we were forgetting to eliminate duplicates in part of the
    package-processing phase in GHC.
    Really I should switch this code over to use the new PackageIndex data
    type in Cabal, which ought to make things simpler.
  5. HC bootstrapping fix: add -I$(GHC_INCLUDE_DIR) to SRC_CC_OPTS

    simonmar committed Nov 12, 2009
    And add a comment explaining why these options are here
  6. A radical overhaul of the coercion infrastucture committed Nov 12, 2009
    * Core Lint now does full checking of kinds and coercion terms
      which picks up kind errors in coercions that were previously
      simply not checked for
    * Coercion.lhs now provides optCoercion which optimises coercion
      terms.  It implements all of Dimitrios's rules
    * The constructors for coercion terms now make no attempt to be
      "smart"; instead we rely solely on the coercion optimiser
    * CoercionTyCons in TyCon.lhs always had a "custom" kinding rule
      (the coKindFun field of CoercionTyCon) but its type was not 
      clever enough to do both 
         (a) *figure out the result kind*, assuming the whole thing
             is well-kinded in the first place
         (b) *check* the kinds of everything, failing gracefully if
             they aren't right. 
      We need (b) for the new CoreLint stuff. The field now has type
      which does the job nicely.
  7. Improve warning message committed Nov 12, 2009
  8. Add an ID monad to MonadUtils (used in kind checking) committed Nov 12, 2009
Commits on Nov 11, 2009
  1. Second attempt to fix #1185 (forkProcess and -threaded)

    simonmar committed Nov 11, 2009
    Patch 1/2: second part of the patch is to libraries/base
    This time without dynamic linker hacks, instead I've expanded the
    existing rts/Globals.c to cache more CAFs, specifically those in
    GHC.Conc.  We were already using this trick for signal handlers, I
    should have realised before.
    It's still quite unsavoury, but we can do away with rts/Globals.c in
    the future when we switch to a dynamically-linked GHCi.
  2. Support for DragonFly BSD

    simonmar committed Nov 11, 2009
    Patches from Goetz Isenmann <>, slightly updated
    for HEAD (the method for configuring platforms in has
  3. The RTS needs hs-suffix-rules-srcdir for BootingFromHc

    simonmar committed Nov 11, 2009
    Patch submitted by Matthias Kilian <>,
    re-recorded against HEAD by me, with a comment added.
  4. No CoreLint warnings if -dno-debug-output is on committed Nov 11, 2009
    The Core Lint warnings are new.  There's only one at the moment,
    namely one to identify recursive INLINE things:
        [RHS of $c>>_als :: forall s_afT a_alJ b_alK.
                            Cpr001_imp.StateTrans s_afT a_alJ
                            -> Cpr001_imp.StateTrans s_afT b_alK
                            -> Cpr001_imp.StateTrans s_afT b_alK]
        INLINE binder is loop breaker: $c>>_als
    This is definitely non-fatal, and typically gets unravelled after
    another simplifier run anyway.  So I'm suppressing such warnings
    for the testsuite, when -dno-debug-output is on.
Commits on Nov 10, 2009
  1. Use relative paths for haddockHTMLs in the inplace package.conf

    igfoo committed Nov 10, 2009
    This means that the docs get built with the correct relative paths.
    When installing, the absolute path will still be used.
  2. Wibbles to the inline-in-InlineRule stuff committed Nov 10, 2009
    The main change is using SimplUtils.updModeForInlineRules
    doesn't overwrite the current setting, it just augments it.
  3. Don't inline a loop breaker, even if it has an INLINE pragma committed Nov 10, 2009
    We preserve the InlineRule on loop breakers, in the hope that they'll
    stop being a loop breaker later.  So don't inline them!
  4. Comments only committed Nov 10, 2009
  5. Implement the PushC rule when optimising casts committed Nov 10, 2009
  6. Preserve strictness when floating coercions committed Nov 10, 2009
    See Note [Preserve strictness when floating coercions]
  7. Make -dverbose-core2core set verbosity = 2 committed Nov 10, 2009
    This ensures that messages coming out with -dshow-passes 
    also come out with -dverbose-core2core
  8. Comments only committed Nov 10, 2009
Commits on Nov 9, 2009
  1. Don't try to rebuild compiler/primop-*.hs-incl when BootingFromHc

    simonmar committed Nov 9, 2009
    Patch submitted by Matthias Kilian <>
Commits on Nov 8, 2009
  1. Put docs into versioned directory names; fixes trac #3532

    igfoo committed Nov 8, 2009
    You can now have multiple versions of a package installed, and
    gen_contents_index will do the right thing.
Commits on Nov 5, 2009
  1. Loop problems in native back ends, update to T3286 fix committed Nov 5, 2009
    The native back ends had difficulties with loops;
    in particular the code for branch-chain elimination
    could run in infinite loops or drop basic blocks.
    The old codeGen didn't expose these problems.
    Also, my fix for T3286 in the new codegen was getting
    applied to too many (some wrong) cases; a better pattern
    match fixed that.
Commits on Sep 18, 2009
  1. Morguing dead code committed Sep 18, 2009
  2. More sensible use of -fnew-codegen and less debugging output committed Sep 18, 2009
  3. Minor refactoring and formatting committed Sep 18, 2009
    Wrote a generic function to extend dataflow results for safe foreign calls.
    Should be able to throw it away when we change the representation of safe foreign calls.
  4. Keep Touch'd variables live through the back end committed Sep 18, 2009
    When we used derived pointers into the middle of an object,
    we need to keep the pointer to the start of the object live.
    We use a "fat machine instruction" with the primitive MO_Touch
    to propagate this information through the back end.
  5. Fixed calling convention for unboxed tuples committed Sep 18, 2009
    Apparently, the arguments should be sorted by pointerhood.
    While we're at it, I rewrote the code that assigns registers
    and stack space to function call and return parameters.
  6. Fix for T3286 in new codegen (related to T3132); plus formatting committed Sep 18, 2009
    If the scrutinee is bottom, the generated Cmm code could have a
    type error when the case arm expected an unboxed floating-point
    value (even though the arm should never be reached).
    Now, we detect this case and avoid producing the type-incorrect