[Git][ghc/ghc][wip/T22084] 6 commits: Boxity: Don't update Boxity unless worker/wrapper follows (#21754)

Simon Peyton Jones (@simonpj) gitlab at gitlab.haskell.org
Tue Oct 4 16:36:10 UTC 2022



Simon Peyton Jones pushed to branch wip/T22084 at Glasgow Haskell Compiler / GHC


Commits:
f5e8f493 by Sebastian Graf at 2022-09-30T18:42:13+02:00
Boxity: Don't update Boxity unless worker/wrapper follows (#21754)

A small refactoring in our Core Opt pipeline and some new functions for
transfering argument boxities from one signature to another to facilitate
`Note [Don't change boxity without worker/wrapper]`.

Fixes #21754.

- - - - -
4baf7b1c by M Farkas-Dyck at 2022-09-30T17:45:47-04:00
Scrub various partiality involving empty lists.

Avoids some uses of `head` and `tail`, and some panics when an argument is null.

- - - - -
95ead839 by Alexis King at 2022-10-01T00:37:43-04:00
Fix a bug in continuation capture across multiple stack chunks

- - - - -
22096652 by Bodigrim at 2022-10-01T00:38:22-04:00
Enforce internal invariant of OrdList and fix bugs in viewCons / viewSnoc

`viewCons` used to ignore `Many` constructor completely, returning `VNothing`.
`viewSnoc` violated internal invariant of `Many` being a non-empty list.

- - - - -
8baf231f by Simon Peyton Jones at 2022-10-03T12:24:37+01:00
Don't keep exit join points so much

We were religiously keeping exit join points throughout, which
had some bad effects (#21148, #22084).

This MR arranges that exit join points are inhibited from inlining
only in /one/ Simplifier pass (right after Exitification).

It's not a big deal, but it shaves 0.1% off compile times.

- - - - -
cd65da06 by Simon Peyton Jones at 2022-10-03T12:24:37+01:00
Inline used-once non-recursive join points very aggressively

Given join j x = rhs in
      joinrec k y = ....j x....

where this is the only occurrence of `j`, we want to inline `j`.
(Unless sm_keep_exits is on.)

This is just a tidy-up really.  It doesn't change allocation, but
getting rid of a binding is always good.

- - - - -


30 changed files:

- compiler/GHC/Cmm/Node.hs
- compiler/GHC/Cmm/Switch.hs
- compiler/GHC/CmmToAsm.hs
- compiler/GHC/CmmToC.hs
- compiler/GHC/CmmToLlvm.hs
- compiler/GHC/Core/Opt/DmdAnal.hs
- compiler/GHC/Core/Opt/Exitify.hs
- compiler/GHC/Core/Opt/Pipeline.hs
- compiler/GHC/Core/Opt/Pipeline/Types.hs
- compiler/GHC/Core/Opt/Simplify/Env.hs
- compiler/GHC/Core/Opt/Simplify/Utils.hs
- compiler/GHC/Core/Opt/SpecConstr.hs
- compiler/GHC/Core/Opt/Specialise.hs
- compiler/GHC/CoreToStg/Prep.hs
- compiler/GHC/Data/BooleanFormula.hs
- compiler/GHC/Data/OrdList.hs
- compiler/GHC/Driver/Config/Core/Lint.hs
- compiler/GHC/Driver/Config/Core/Opt/Simplify.hs
- compiler/GHC/Linker/Loader.hs
- compiler/GHC/Llvm/Types.hs
- compiler/GHC/Parser/PostProcess.hs
- compiler/GHC/Tc/Module.hs
- compiler/GHC/Types/Demand.hs
- compiler/GHC/Types/Name/Reader.hs
- compiler/GHC/Unit/State.hs
- compiler/GHC/Utils/Misc.hs
- rts/Continuation.c
- testsuite/tests/rts/continuations/all.T
- + testsuite/tests/rts/continuations/cont_stack_overflow.hs
- + testsuite/tests/simplCore/should_compile/T21148.hs


The diff was not included because it is too large.


View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/f9a5a7394d7d7108b827c50441eb48237f75ffea...cd65da060f00bd74351e6324ddf567f19e31def4

-- 
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/f9a5a7394d7d7108b827c50441eb48237f75ffea...cd65da060f00bd74351e6324ddf567f19e31def4
You're receiving this email because of your account on gitlab.haskell.org.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.haskell.org/pipermail/ghc-commits/attachments/20221004/2ce487fa/attachment-0001.html>


More information about the ghc-commits mailing list