[Git][ghc/ghc][wip/marge_bot_batch_merge_job] 17 commits: rts/CNF: Fix fixup comparison function

Marge Bot gitlab at gitlab.haskell.org
Tue May 12 06:38:54 UTC 2020



 Marge Bot pushed to branch wip/marge_bot_batch_merge_job at Glasgow Haskell Compiler / GHC


Commits:
a09add85 by Ben Gamari at 2020-05-12T02:38:30-04:00
rts/CNF: Fix fixup comparison function

Previously we would implicitly convert the difference between two words
to an int, resulting in an integer overflow on 64-bit machines.

Fixes #16992

- - - - -
131d388f by Ömer Sinan Ağacan at 2020-05-12T02:38:33-04:00
Pack some of IdInfo fields into a bit field

This reduces residency of compiler quite a bit on some programs.
Example stats when building T10370:

Before:

   2,871,242,832 bytes allocated in the heap
   4,693,328,008 bytes copied during GC
      33,941,448 bytes maximum residency (276 sample(s))
         375,976 bytes maximum slop
              83 MiB total memory in use (0 MB lost due to fragmentation)

After:

   2,858,897,344 bytes allocated in the heap
   4,629,255,440 bytes copied during GC
      32,616,624 bytes maximum residency (278 sample(s))
         314,400 bytes maximum slop
              80 MiB total memory in use (0 MB lost due to fragmentation)

So -3.9% residency, -1.3% bytes copied and -0.4% allocations.

Fixes #17497

Metric Decrease:
    T9233
    T9675

- - - - -
1d2aaa2e by Ben Gamari at 2020-05-12T02:38:34-04:00
get-win32-tarballs: Fix base URL

Revert a change previously made for testing purposes.

- - - - -
bd136bb7 by Ben Gamari at 2020-05-12T02:38:34-04:00
get-win32-tarballs: Improve diagnostics output

- - - - -
156f801b by Simon Jakobi at 2020-05-12T02:38:35-04:00
docs: Add examples for Data.Semigroup.Arg{Min,Max}

Context: #17153

- - - - -
9f0bc0fa by Baldur Blöndal at 2020-05-12T02:38:37-04:00
Predicate, Equivalence derive via `.. -> a -> All'

- - - - -
80263d69 by Ben Gamari at 2020-05-12T02:38:38-04:00
Add few cleanups of the CAF logic

Give the NameSet of non-CAFfy names a proper newtype to distinguish it
from all of the other NameSets floating about.

- - - - -
da42dc1d by Emeka Nkurumeh at 2020-05-12T02:38:40-04:00
fix printf warning when using with ghc with clang on mingw
- - - - -
0855c928 by Daniel Gröber at 2020-05-12T02:38:42-04:00
Fix non power-of-two Storable.alignment in Capi_Ctype tests

Alignments passed to alloca and friends must be a power of two for the code
in allocatePinned to work properly. Commit 41230e2601 ("Zero out pinned
block alignment slop when profiling") introduced an ASSERT for this but
this test was still violating it.

- - - - -
392cc02c by Daniel Gröber at 2020-05-12T02:38:42-04:00
Improve ByteArray# documentation regarding alignment

- - - - -
edaec729 by Daniel Gröber at 2020-05-12T02:38:42-04:00
Document word-size rounding of ByteArray# memory (Fix #14731)

- - - - -
c1e4d284 by Daniel Gröber at 2020-05-12T02:38:42-04:00
Throw IOError when allocaBytesAligned gets non-power-of-two align

- - - - -
80614bd8 by Sebastian Graf at 2020-05-12T02:38:42-04:00
CprAnal: Don't attach CPR sigs to expandable bindings (#18154)

Instead, look through expandable unfoldings in `cprTransform`.
See the new Note [CPR for expandable unfoldings]:

```
Long static data structures (whether top-level or not) like

  xs = x1 : xs1
  xs1 = x2 : xs2
  xs2 = x3 : xs3

should not get CPR signatures, because they

  * Never get WW'd, so their CPR signature should be irrelevant after analysis
    (in fact the signature might even be harmful for that reason)
  * Would need to be inlined/expanded to see their constructed product
  * Recording CPR on them blows up interface file sizes and is redundant with
    their unfolding. In case of Nested CPR, this blow-up can be quadratic!

But we can't just stop giving DataCon application bindings the CPR property,
for example

  fac 0 = 1
  fac n = n * fac (n-1)

fac certainly has the CPR property and should be WW'd! But FloatOut will
transform the first clause to

  lvl = 1
  fac 0 = lvl

If lvl doesn't have the CPR property, fac won't either. But lvl doesn't have a
CPR signature to extrapolate into a CPR transformer ('cprTransform'). So
instead we keep on cprAnal'ing through *expandable* unfoldings for these arity
0 bindings via 'cprExpandUnfolding_maybe'.

In practice, GHC generates a lot of (nested) TyCon and KindRep bindings, one
for each data declaration. It's wasteful to attach CPR signatures to each of
them (and intractable in case of Nested CPR).
```

Fixes #18154.

- - - - -
5888e85a by Ben Gamari at 2020-05-12T02:38:43-04:00
users-guide: Add discussion of shared object naming

Fixes #18074.

- - - - -
b9f092dd by Ben Gamari at 2020-05-12T02:38:43-04:00
testsuite: Print sign of performance changes

Executes the minor formatting change in the tabulated performance
changes suggested in #18135.

- - - - -
16abaa9b by Ben Gamari at 2020-05-12T02:38:44-04:00
testsuite: Add testcase for #18129

- - - - -
8c19b8d0 by Ivan-Yudin at 2020-05-12T02:38:45-04:00
doc: Reformulate the opening paragraph of Ch. 4 in User's guide

Removes mentioning of Hugs
(it is not helpful for new users anymore).

Changes the wording for the rest of the paragraph.

Fixes #18132.

- - - - -


30 changed files:

- compiler/GHC/Builtin/primops.txt.pp
- compiler/GHC/Cmm/Info/Build.hs
- compiler/GHC/Core/Opt/CprAnal.hs
- compiler/GHC/Driver/Main.hs
- compiler/GHC/Iface/Make.hs
- compiler/GHC/Iface/UpdateCafInfos.hs
- compiler/GHC/Types/Id/Info.hs
- compiler/GHC/Types/Name/Set.hs
- docs/users_guide/ghci.rst
- docs/users_guide/packages.rst
- docs/users_guide/phases.rst
- includes/rts/Messages.h
- libraries/base/Data/Functor/Contravariant.hs
- libraries/base/Data/Semigroup.hs
- libraries/base/Foreign/Marshal/Alloc.hs
- libraries/base/Foreign/Storable.hs
- libraries/base/changelog.md
- + libraries/ghc-compact/tests/T16992.hs
- + libraries/ghc-compact/tests/T16992.stdout
- libraries/ghc-compact/tests/all.T
- mk/get-win32-tarballs.py
- rts/sm/CNF.c
- testsuite/driver/runtests.py
- testsuite/tests/ffi/should_run/Capi_Ctype_001.hsc
- testsuite/tests/ffi/should_run/Capi_Ctype_A_001.hsc
- testsuite/tests/ffi/should_run/Capi_Ctype_A_002.hsc
- testsuite/tests/numeric/should_compile/T14170.stdout
- testsuite/tests/numeric/should_compile/T14465.stdout
- testsuite/tests/numeric/should_compile/T7116.stdout
- testsuite/tests/simplCore/should_compile/T13143.stderr


The diff was not included because it is too large.


View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/9e4bca9fb1d556cbc553aae5a6fb81b896fe8d11...8c19b8d0b68c1f7d05fdf3ccd53d00e0916d0d8b

-- 
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/9e4bca9fb1d556cbc553aae5a6fb81b896fe8d11...8c19b8d0b68c1f7d05fdf3ccd53d00e0916d0d8b
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/20200512/586c7acf/attachment.html>


More information about the ghc-commits mailing list