
Ben Gamari pushed to branch ghc-9.14 at Glasgow Haskell Compiler / GHC Commits: d5dab939 by Simon Peyton Jones at 2025-09-02T15:03:52-04:00 Take more care in zonkEqTypes on AppTy/AppTy This patch fixes #26256. See Note [zonkEqTypes and the PKTI] in GHC.Tc.Solver.Equality (cherry picked from commit 18036d5205ac648bb245217519fed2fd931a9982) - - - - - 5c994363 by Andreas Klebinger at 2025-09-02T15:04:00-04:00 Make unexpected LLVM versions a warning rather than an error. Typically a newer LLVM version *will* work so erroring out if a user uses a newer LLVM version is too aggressive. Fixes #25915 (cherry picked from commit 50842f83f467ff54dd22470559a7af79d2025c03) - - - - - dbe870cd by Reed Mullanix at 2025-09-02T15:04:56-04:00 ghc-internal: Fix naturalAndNot for NB/NS case When the first argument to `naturalAndNot` is larger than a `Word` and the second is `Word`-sized, `naturalAndNot` will truncate the result: ```
naturalAndNot ((2 ^ 65) .|. (2 ^ 3)) (2 ^ 3) 0
In contrast, `naturalAndNot` does not truncate when both arguments are larger than a `Word`, so this appears to be a bug.
Luckily, the fix is pretty easy: we just need to call `bigNatAndNotWord#` instead of truncating.
Fixes #26230
(cherry picked from commit a766286fe759251eceb304c54ba52841c2a51f86)
- - - - -
ceb55a1f by Zubin Duggal at 2025-09-02T15:05:08-04:00
testsuite: Be more permissive when filtering out GNU_PROPERTY_TYPE linker warnings
The warning text is slightly different with ld.bfd.
Fixes #26249
(cherry picked from commit 51c701fef034e2062809eed5de3a51bb0a4243ba)
- - - - -
a85edeb7 by Teo Camarasu at 2025-09-02T15:05:18-04:00
rts: ensure MessageBlackHole.link is always a valid closure
We turn a MessageBlackHole into an StgInd in wakeBlockingQueue().
Therefore it's important that the link field, which becomes the
indirection field, always points to a valid closure.
It's unclear whether it's currently possible for the previous behaviour
to lead to a crash, but it's good to be consistent about this invariant nonetheless.
Co-authored-by: Andreas Klebinger <klebinger.andreas@gmx.at>
(cherry picked from commit a8b2fbae6bcf20bc2f3fe58803096d2a9c5fc43d)
- - - - -
2fded9af by Teo Camarasu at 2025-09-02T15:05:23-04:00
rts: spin if we see a WHITEHOLE in messageBlackHole
When a BLACKHOLE gets cancelled in raiseAsync, we indirect to a THUNK.
GC can then shortcut this, replacing our BLACKHOLE with a fresh THUNK.
This THUNK is not guaranteed to have a valid indirectee field.
If at the same time, a message intended for the previous BLACKHOLE is
processed and concurrently we BLACKHOLE the THUNK, thus temporarily
turning it into a WHITEHOLE, we can get a segfault, since we look at the
undefined indirectee field of the THUNK
The fix is simple: spin if we see a WHITEHOLE, and it will soon be
replaced with a valid BLACKHOLE.
Resolves #26205
(cherry picked from commit 4021181ee0860aca2054883a531f3312361cc701)
- - - - -
addff92e by Cheng Shao at 2025-09-02T15:07:22-04:00
hadrian: enforce have_llvm=False for wasm32/js
This patch fixes hadrian to always pass have_llvm=False to the
testsuite driver for wasm32/js targets. These targets don't really
support the LLVM backend, and the optllvm test way doesn't work. We
used to special-case wasm32/js to avoid auto-adding optllvm way in
testsuite/config/ghc, but this is still problematic if someone writes
a new LLVM-related test and uses something like when(have_llvm(),
extra_ways(["optllvm"])). So better just enforce have_llvm=False for
these targets here.
(cherry picked from commit 1cdc6f46c4168dd92a8f5ea0c398b67fc59449a9)
- - - - -
73364af4 by fendor at 2025-09-02T15:07:38-04:00
rts: Strip lower three bits when hashing Word instead of lower eight bits
(cherry picked from commit 58e46da9dad572b95b4e354d0a0ed25ce9af5d02)
- - - - -
ba8b5927 by Cheng Shao at 2025-09-02T15:07:46-04:00
libffi: update to 3.5.2
Bumps libffi submodule.
(cherry picked from commit 45dbfa23f508f221b6aeb667783a928511a7654e)
- - - - -
d4aeb662 by Simon Peyton Jones at 2025-09-02T15:07:53-04:00
Take yet more care with reporting redundant constraints
This small patch fixes #25992, which relates to reporting redundant
constraints on default-method declarations.
See (TRC5) in Note [Tracking redundant constraints]
(cherry picked from commit f4bac60722ac990d349bdffa3e4fcfcaf6d8f11b)
- - - - -
802372b1 by Vekhir -- at 2025-09-02T15:08:20-04:00
Bump Cabal dependency
(cherry picked from commit 276f8ea8d369b202549a2e30be9b88a95a329083)
- - - - -
893652db by Simon Peyton Jones at 2025-09-02T15:08:30-04:00
Start with empty inerts in shortcut solving
When short-cut solving we were starting with an inert set that had
unsolved Wanteds. This caused an infinite loop (#26314), because a
typechecker plugin kept being given that unsolved Wanted.
It's better just to start with an empty inert set
(cherry picked from commit ccda188d726804e4154de9318c72c5a656f3b015)
- - - - -
2a888147 by fendor at 2025-09-02T15:08:42-04:00
Remove deprecated functions from the ghci package
(cherry picked from commit f0a19d744e339189cfd63b52585e16043ed4997a)
- - - - -
b8b09969 by fendor at 2025-09-02T15:09:26-04:00
base: Remove unstable heap representation details from GHC.Exts
(cherry picked from commit ebeb991b7c81a5e5f5c09aba9a4af0f85e656253)
- - - - -
79cf7742 by Cheng Shao at 2025-09-02T15:10:28-04:00
wasm: ensure setKeepCAFs() is called in ghci
This patch is a critical bugfix for #26106, see comment and linked
issue for details.
(cherry picked from commit 10f06163d9adcb3b6e6438f1524faaca3bf6c3b2)
- - - - -
65325218 by Simon Peyton Jones at 2025-09-02T15:10:44-04:00
Comments only
(cherry picked from commit 00478944861fe3ab146d759898ea0285484d8387)
- - - - -
ca12f880 by Simon Peyton Jones at 2025-09-02T15:10:44-04:00
Type-family occurs check in unification
The occurs check in `GHC.Core.Unify.uVarOrFam` was inadequate in dealing
with type families.
Better now. See Note [The occurs check in the Core unifier].
As I did this I realised that the whole apartness thing is trickier than I
thought: see the new Note [Shortcomings of the apartness test]
(cherry picked from commit a78845896d7f5b692372c137fd7a73bcdf94eddb)
- - - - -
f6a086c3 by Simon Peyton Jones at 2025-09-04T10:34:26-04:00
Fix a long standing bug in the coercion optimiser
We were mis-optimising ForAllCo, leading to #26345
Part of the poblem was the tricky tower of abstractions leading to
the dreadful
GHC.Core.TyCo.Subst.substForAllCoTyVarBndrUsing
This function was serving two masters: regular substitution, but also
coercion optimsation. So tricky was it that it did so wrong.
In this MR I locate all the fancy footwork for coercion optimisation
in GHC.Core.Coercion.Opt, where it belongs. That leaves substitution
free to be much simpler.
(cherry picked from commit fb9cc8825f37b1d7f1bc19d5a5c1425c7613e81a)
Metric Decrease:
CoOpt_Read
- - - - -
44 changed files:
- compiler/GHC/Core/Coercion.hs
- compiler/GHC/Core/Coercion/Opt.hs
- compiler/GHC/Core/TyCo/Compare.hs
- compiler/GHC/Core/TyCo/Subst.hs
- compiler/GHC/Core/Type.hs
- compiler/GHC/Core/Unify.hs
- compiler/GHC/Driver/Errors/Ppr.hs
- compiler/GHC/Tc/Solver/Dict.hs
- compiler/GHC/Tc/Solver/Equality.hs
- compiler/GHC/Tc/Solver/Monad.hs
- compiler/GHC/Tc/Solver/Solve.hs
- compiler/GHC/Tc/TyCl/Instance.hs
- compiler/GHC/Tc/Types/Origin.hs
- compiler/GHC/Tc/Utils/Unify.hs
- hadrian/hadrian.cabal
- hadrian/src/Settings/Builders/RunTest.hs
- libffi-tarballs
- libraries/base/changelog.md
- libraries/base/src/GHC/Exts.hs
- libraries/ghc-bignum/changelog.md
- libraries/ghc-internal/src/GHC/Internal/Bignum/Natural.hs
- libraries/ghci/GHCi/CreateBCO.hs
- libraries/ghci/GHCi/TH.hs
- libraries/ghci/ghci.cabal.in
- rts/Hash.c
- rts/Messages.c
- rts/StgMiscClosures.cmm
- rts/Updates.h
- testsuite/config/ghc
- testsuite/driver/testlib.py
- − testsuite/tests/module/T21752.stderr
- + testsuite/tests/numeric/should_run/T26230.hs
- + testsuite/tests/numeric/should_run/T26230.stdout
- testsuite/tests/numeric/should_run/all.T
- + testsuite/tests/partial-sigs/should_compile/T26256.hs
- + testsuite/tests/partial-sigs/should_compile/T26256.stderr
- testsuite/tests/partial-sigs/should_compile/all.T
- + testsuite/tests/typecheck/should_compile/T25992a.hs
- + testsuite/tests/typecheck/should_compile/T26256a.hs
- + testsuite/tests/typecheck/should_compile/T26345.hs
- + testsuite/tests/typecheck/should_compile/T26346.hs
- + testsuite/tests/typecheck/should_compile/T26358.hs
- testsuite/tests/typecheck/should_compile/all.T
- utils/jsffi/dyld.mjs
The diff was not included because it is too large.
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/5f9c0b626a05313c01ce68f6defe8c907871b77d...f6a086c355eb027cc40a2b9645eedd353601dfb6
--
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/5f9c0b626a05313c01ce68f6defe8c907871b77d...f6a086c355eb027cc40a2b9645eedd353601dfb6
You're receiving this email because of your account on gitlab.haskell.org.