1. 25 Mar, 2003 2 commits
  2. 24 Mar, 2003 4 commits
    • simonmar's avatar
      [project @ 2003-03-24 16:18:26 by simonmar] · 2e9a75d1
      simonmar authored
      warning elimination
    • simonmar's avatar
      [project @ 2003-03-24 15:33:25 by simonmar] · 25efe5a4
      simonmar authored
      A couple of changes related to bug #2 in the previous commit:
       - follow IND_STATICs, now that we can check whether
         we end up in to-space or not
       - improve the commentary
    • simonmar's avatar
      [project @ 2003-03-24 14:46:53 by simonmar] · b3f53081
      simonmar authored
      Fix some bugs in compacting GC.
      Bug 1: When threading the fields of an AP or PAP, we were grabbing the
      info table of the function without unthreading it first.
      Bug 2: eval_thunk_selector() might accidentally find itself in
      to-space when going through indirections in a compacted generation.
      We must check for this case and bale out if necessary.
      Bug 3: This is somewhat more nasty.  When we have an AP or PAP that
      points to a BCO, the layout info for the AP/PAP is in the BCO's
      instruction array, which is two objects deep from the AP/PAP itself.
      The trouble is, during compacting GC, we can only safely look one
      object deep from the current object, because pointers from objects any
      deeper might have been already updated to point to their final
      The solution is to put the arity and bitmap info for a BCO into the
      BCO object itself.  This means BCOs become variable-length, which is a
      slight annoyance, but it also means that looking up the arity/bitmap
      is quicker.  There is a slight reduction in complexity in the byte
      code generator due to not having to stuff the bitmap at the front of
      the instruction stream.
    • simonmar's avatar
      [project @ 2003-03-24 11:23:20 by simonmar] · 82387309
      simonmar authored
      #ifdef some more code that belongs to the old strictness analyser.
      It turns out we were still compiling the Demand and SaLib modules,
      which aren't required unless OLD_STRICTNESS is on (do we still need
  3. 22 Mar, 2003 1 commit
  4. 21 Mar, 2003 6 commits
    • sof's avatar
      [project @ 2003-03-21 16:18:37 by sof] · 557bca73
      sof authored
      Friday morning code-wibbling:
      - made RetainerProfile.c:firstStack a 'static'
      - added RetainerProfile.c:retainerStackBlocks()
    • sof's avatar
      [project @ 2003-03-21 15:48:06 by sof] · d4c65d1e
      sof authored
      drop FILE_SIZE (hasn't been needed by NCG for the past 5 years or so)
    • sof's avatar
      [project @ 2003-03-21 15:45:56 by sof] · 107a09db
      sof authored
      reliably clean out mk* binaries
    • simonmar's avatar
      [project @ 2003-03-21 13:54:27 by simonmar] · 2e6d322e
      simonmar authored
      Modifications to the way we calculate CafInfo during tidying (again).
      The previous hack of setting the CafInfo on all non-top-level bindings
      to NoCafRefs was a hack, and it came back to bite us: when CorePrep
      floats out a let to the top level it doesn't create a new binding, and
      the existing let binder happens to say NoCafRefs which is unsafe.  It
      was caught by an ASSERT in the CoreToStg when compiling the libraries
      without -O - compiling without -O tends to result in more
      opportunities for CorePrep to float things to the top level.
      Now, we calculate CafInfo on the pre-tidied expressions, using the
      mapping from Ids to Ids that is being built up during tidying.  This
      avoids one loop, but will be slightly slower due to the extra lookups.
      However, it means we don't need to set the CafInfo on non-top-level
      binders to NoCafRefs.
    • simonmar's avatar
      [project @ 2003-03-21 10:59:20 by simonmar] · 63a5c646
      simonmar authored
      GNU ar seems to have trouble with duplicate object file names if you
      use the 's' modifier, so detect GNU ar here and use a simple 'ar q'
      command to create archives.
      This bug was tickled when I replaced an 'ar q' with '$(AR)' in
      target.mk yesterday: the default $(AR) is 'ar clqs'.
    • simonpj's avatar
      [project @ 2003-03-21 09:22:28 by simonpj] · 301f1535
      simonpj authored
      Notes about constructor info tables
  5. 20 Mar, 2003 6 commits
  6. 19 Mar, 2003 5 commits
  7. 18 Mar, 2003 3 commits
    • simonmar's avatar
      [project @ 2003-03-18 14:36:56 by simonmar] · 428c025e
      simonmar authored
      Fix a profiling crash on Windows.
      fprint_ccs used snprintf() to avoid overflowing a buffer; on mingw32
      where snprintf() doesn't exist we were just using the straight
      sprintf(), which inevitably lead to a crash.  Rewritten to use a
      homegrown non-overflowing string copying function - it actually looks
      nicer now, anwyay.
    • simonmar's avatar
      [project @ 2003-03-18 10:28:15 by simonmar] · c1d0aa93
      simonmar authored
      This should have been committed along with rev. 1.36 of Main.c (and
      others) yesterday, but for some reason it got left out.
      Change the way Main.main is run, so it now doesn't force the return
      value.  Now 'main = return undefined' will run and exit successfully.
      The change affects finalizers too - but since they have type IO (), it
      won't do any harm not to evaluate the ().
    • simonmar's avatar
      [project @ 2003-03-18 10:12:37 by simonmar] · aa448d76
      simonmar authored
      Fix wibble in previous commit (fixes broken bootstrap)
  8. 17 Mar, 2003 2 commits
    • simonmar's avatar
      [project @ 2003-03-17 14:51:00 by simonmar] · 1f6eb553
      simonmar authored
      Fix for lexing of floating point numbers.  '9e2' should be a float.
      Noticed-by: Ross Paterson.
    • simonmar's avatar
      [project @ 2003-03-17 14:47:47 by simonmar] · 74b46a5d
      simonmar authored
      Haskell quiz:  what should this program do?
        main = return undefined
      answer: run to completion and exit successfully.  GHC erroneously
      evaluates the returned value from main, which causes this example to
      fail with an uncaught exception (the evaluation is even done outside
      of the main exception handler!).
  9. 16 Mar, 2003 1 commit
  10. 14 Mar, 2003 1 commit
  11. 11 Mar, 2003 6 commits
  12. 10 Mar, 2003 3 commits
    • simonmar's avatar
      [project @ 2003-03-10 13:27:34 by simonmar] · bda047d0
      simonmar authored
      Use STK_CHK_NP rather than STK_CHK_GEN in the entry code for AP and
      AP_STACK thunks.
      The reason is that if the check fails, on return the closure might
      have been blackholed (perhaps due to lazy blackholing, or even because
      another thread has entered it), so we *must* enter the closure to
      continue, rather than just continuing at the original entry point.
      All compiler-generated thunks do this anyway, I think these are the
      only cases of thunks which don't follow the rule.
      Thanks to Robert Ennals for spotting, and correctly diagnosing, the
    • stolz's avatar
      [project @ 2003-03-10 12:48:10 by stolz] · 4e25c045
      stolz authored
      Fix typo
    • umuta's avatar
      [project @ 2003-03-10 10:30:26 by umuta] · 3c709aa7
      umuta authored
      Fix compilation problem on mingw32