Skip to content
Snippets Groups Projects
  1. Mar 22, 2019
  2. Mar 13, 2019
  3. Mar 08, 2019
    • Sebastian Graf's avatar
      Always do the worker/wrapper split for NOINLINEs · 1675d40a
      Sebastian Graf authored and Marge Bot's avatar Marge Bot committed
      Trac #10069 revealed that small NOINLINE functions didn't get split
      into worker and wrapper. This was due to `certainlyWillInline`
      saying that any unfoldings with a guidance of `UnfWhen` inline
      unconditionally. That isn't the case for NOINLINE functions, so we
      catch this case earlier now.
      
      Nofib results:
      
      --------------------------------------------------------------------------------
              Program         Allocs    Instrs
      --------------------------------------------------------------------------------
       fannkuch-redux          -0.3%      0.0%
                   gg          +0.0%     +0.1%
             maillist          -0.2%     -0.2%
              minimax           0.0%     -0.8%
      --------------------------------------------------------------------------------
                  Min          -0.3%     -0.8%
                  Max          +0.0%     +0.1%
       Geometric Mean          -0.0%     -0.0%
      
      Fixes #10069.
      
      -------------------------
      Metric Increase:
          T9233
      -------------------------
      1675d40a
  4. Mar 07, 2019
  5. Feb 24, 2019
  6. Feb 10, 2019
  7. Feb 09, 2019
  8. Feb 04, 2019
  9. Jan 30, 2019
  10. Jan 12, 2019
    • Ömer Sinan Ağacan's avatar
      Fix negative mutator time in GC stats in prof builds · 19670bc3
      Ömer Sinan Ağacan authored
      Because garbage collector calls `retainerProfile()` and `heapCensus()`,
      GC times normally include some of PROF times too. To fix this we have
      these lines:
      
          // heapCensus() is called by the GC, so RP and HC time are
          // included in the GC stats.  We therefore subtract them to
          // obtain the actual GC cpu time.
          stats.gc_cpu_ns      -=  prof_cpu;
          stats.gc_elapsed_ns  -=  prof_elapsed;
      
      These variables are later used for calculating GC time excluding the
      final GC (which should be attributed to EXIT).
      
          exit_gc_elapsed      = stats.gc_elapsed_ns - start_exit_gc_elapsed;
      
      The problem is if we subtract PROF times from `gc_elapsed_ns` and then
      subtract `start_exit_gc_elapsed` from the result, we end up subtracting
      PROF times twice, because `start_exit_gc_elapsed` also includes PROF
      times.
      
      We now subtract PROF times from GC after the calculations for EXIT and
      MUT times. The existing assertion that checks
      
          INIT + MUT + GC + EXIT = TOTAL
      
      now holds. When we subtract PROF numbers from GC, and a new assertion
      
          INIT + MUT + GC + PROF + EXIT = TOTAL
      
      also holds.
      
      Fixes #15897. New assertions added in this commit also revealed #16102,
      which is also fixed by this commit.
      19670bc3
  11. Dec 25, 2018
    • Ben Gamari's avatar
      testsuite: Fix a variety of issues when building with integer-simple · 99378207
      Ben Gamari authored
       * Mark arith011 as broken with integer-simple
      
         As noted in #16091, arith011 fails when run against integer-simple with a
         "divide by zero" exception. This suggests that integer-gmp and integer-simple
         are handling division by zero differently.
      
       * This also fixes broken_without_gmp; the lack of types made the previous
         failure silent, sadly. Improves situation of #16043.
      
       * Mark several tests implicitly depending upon integer-gmp as broken
         with integer-simple. These expect to see Core coming from integer-gmp,
         which breaks with integer-simple.
      
       * Increase runtime timeout multiplier of T11627a with integer-simple
      
         I previously saw that T11627a timed out in all profiling ways when run against
         integer-simple. I suspect this is due to integer-simple's rather verbose heap
         representation. Let's see whether increasing the runtime timeout helps.
      
         Fixes test for #11627.
      
      This is all in service of fixing #16043.
      99378207
    • Ben Gamari's avatar
      testsuite: Enable T11627a on Darwin · 6d9d6f9a
      Ben Gamari authored
      The retainer profiler no longer uses the C stack for its mark stack (#14758).
      Consequently even the small C stack provided on Darwin should be sufficient to
      run this test. See #11627
      6d9d6f9a
  12. Dec 22, 2018
  13. Oct 17, 2018
  14. Jul 13, 2018
    • Ömer Sinan Ağacan's avatar
      Fix processHeapClosureForDead CONSTR_NOCAF case · 2625f131
      Ömer Sinan Ağacan authored
      CONSTR_NOCAF was introduced with 55d535da as a replacement for
      CONSTR_STATIC and CONSTR_NOCAF_STATIC, however, as explained in Note
      [static constructors], we copy CONSTR_NOCAFs (which can also be seen in
      evacuate) during GC, and they can become dead, like other CONSTR_X_Ys.
      processHeapClosureForDead is updated to reflect this.
      
      Test Plan: Validates on x86_64. Existing failures on i386.
      
      Reviewers: simonmar, bgamari, erikd
      
      Reviewed By: simonmar, bgamari
      
      Subscribers: rwbarton, thomie, carter
      
      GHC Trac Issues: #7836, #15063, #15087, #15165
      
      Differential Revision: https://phabricator.haskell.org/D4928
      2625f131
  15. Jul 01, 2018
  16. Jun 20, 2018
  17. Jun 17, 2018
  18. May 20, 2018
  19. May 01, 2018
  20. Mar 25, 2018
  21. Mar 06, 2018
    • Simon Marlow's avatar
      Fix interpreter with profiling · 488d63d6
      Simon Marlow authored and Ben Gamari's avatar Ben Gamari committed
      This was broken by D3746 and/or D3809, but unfortunately we didn't
      notice because CI at the time wasn't building the profiling way.
      
      Test Plan:
      ```
      cd testsuite/test/profiling/should_run
      make WAY=ghci-ext-prof
      ```
      
      Reviewers: bgamari, michalt, hvr, erikd
      
      Subscribers: rwbarton, thomie, carter
      
      GHC Trac Issues: #14705
      
      Differential Revision: https://phabricator.haskell.org/D4437
      488d63d6
  22. Mar 02, 2018
  23. Feb 13, 2018
    • Ömer Sinan Ağacan's avatar
      Collect CCs in CorePrep, including CCs in unfoldings · 59574058
      Ömer Sinan Ağacan authored
      This patch includes two changes:
      
      1. Move cost centre collection from `SCCfinal` to `CorePrep`, to be able
         to collect cost centres in unfoldings. `CorePrep` drops unfoldings, so
         that's the latest stage in the compilation pipeline for this.
      
         After this change `SCCfinal` no longer collects all cost centres, but
         it still generates & collects CAF cost centres + updates cost centre
         stacks of `StgRhsClosure` and `StgRhsCon`s.
      
         This fixes #5889.
      
      2. Initialize cost centre stack fields of `StgRhs` in `coreToStg`. With
         this we no longer need to update cost centre stack fields in
         `SCCfinal`, so that module is removed.
      
         Cost centre initialization explained in Note [Cost-centre
         initialization plan].
      
         Because with -fcaf-all we need to attach a new cost-centre to each
         CAF, `coreTopBindToStg` now returns `CollectedCCs`.
      
      Test Plan: validate
      
      Reviewers: simonpj, bgamari, simonmar
      
      Reviewed By: simonpj, bgamari
      
      Subscribers: rwbarton, thomie, carter
      
      GHC Trac Issues: #5889
      
      Differential Revision: https://phabricator.haskell.org/D4325
      59574058
  24. Feb 02, 2018
    • Ben Gamari's avatar
      testsuite: Fix scc001 profile output · c3ccd835
      Ben Gamari authored
      CircleCI seems to suggest that the cost center ordering is wrong in the prof
      way. I'm beginning to wonder whether there is some non-determinism here. If only
      I know what this test was supposed to be testing.
      c3ccd835
  25. Jan 31, 2018
  26. Jan 30, 2018
  27. Dec 18, 2017
  28. Nov 22, 2017
  29. Nov 09, 2017
  30. May 12, 2017
    • David Feuer's avatar
      Automatically add SCCs to INLINABLE bindings · ab91daf2
      David Feuer authored
      Instead of excluding `isAnyInlinePragma`, just exclude
      `isInlinePragma`. This makes GHC behave as documented;
      the user's guide only indicates that GHC does not automatically
      add SCCs to `INLINE` bindings.
      
      Fixes #12962.
      
      Reviewers: austin, bgamari
      
      Reviewed By: bgamari
      
      Subscribers: DemiMarie, osa1, Mikolaj, simonpj, rwbarton, thomie
      
      GHC Trac Issues: #12962
      
      Differential Revision: https://phabricator.haskell.org/D3550
      ab91daf2
  31. Mar 29, 2017
  32. Mar 14, 2017
  33. Feb 26, 2017
    • rwbarton's avatar
      tests: remove extra_files.py (#12223) · 3415bcaa
      rwbarton authored and Ben Gamari's avatar Ben Gamari committed
      The script I used is included as testsuite/driver/kill_extra_files.py,
      though at this point it is for mostly historical interest.
      
      Some of the tests in libraries/hpc relied on extra_files.py, so this
      commit includes an update to that submodule.
      
      One test in libraries/process also relies on extra_files.py, but we
      cannot update that submodule so easily, so for now we special-case it
      in the test driver.
      3415bcaa
  34. Jan 22, 2017
  35. Jan 06, 2017
    • Simon Marlow's avatar
      More fixes for #5654 · 3a18baff
      Simon Marlow authored
      * In stg_ap_0_fast, if we're evaluating a thunk, the thunk might
        evaluate to a function in which case we may have to adjust its CCS.
      
      * The interpreter has its own implementation of stg_ap_0_fast, so we
        have to do the same shenanigans with creating empty PAPs and copying
        PAPs there.
      
      * GHCi creates Cost Centres as children of CCS_MAIN, which enterFunCCS()
        wrongly assumed to imply that they were CAFs.  Now we use the is_caf
        flag for this, which we have to correctly initialise when we create a
        Cost Centre in GHCi.
      3a18baff
Loading