-
42cf12ed
by Simon Peyton Jones at 2026-06-10T18:17:15+05:30
QuickLook's tcInstFun should make instantiation variables directly
tcInstFun must make "instantiation variables", not regular
unification variables, when instantiating function types. That was
previously implemented by a hack: set the /ambient/ level to QLInstTyVar.
But the hack finally bit me, when I was refactoring WhatUnifications.
And it was always wrong: see the now-expunged (TCAPP2) note.
This commit does it right, by making tcInstFun call its own
instantiation functions. That entails a small bit of duplication,
but the result is much, much cleaner.
(cherry picked from commit 231adc30be97ae51650aff7a40e00e05f4876af6)
-
ba2aa75d
by Zubin Duggal at 2026-06-10T18:17:16+05:30
Revert "docs: note #26543 in known bugs"
This reverts commit ebc6d49bd309bb843bc58e8c712ade767818e9ac.
Obsolete now that the fix from MR 14474 (commit 231adc30) is backported.
-
770190bc
by Luite Stegeman at 2026-06-10T18:17:16+05:30
Fix assert in Interpreter.c
If we skip exactly the number of words on the stack we end up on
the first word in the next chunk.
(cherry picked from commit 404b71c181bde4256565307d495cd2fa124d02f1)
-
e3d88c9e
by Ben Gamari at 2026-06-10T18:17:16+05:30
rts/Interpreter: Factor out ctoi tuple info tables into data
Instead of a massive case let's put this into data which we can reuse
elsewhere.
(cherry picked from commit d2b89603425b6d08df199deb7b84cfdbd711869a)
-
660297cc
by Luite Stegeman at 2026-06-10T18:17:16+05:30
Support arbitrary size unboxed tuples in bytecode
This stores the size (number of words on the stack) of the next
expected tuple in the TSO, ctoi_spill_size field, eliminating
the need of stg_ctoi_tN frames for each size.
Note: On 32 bit platform there is still a bytecode tuple size
limit of 255 words on the stack.
Fixes #26946
(cherry picked from commit a85bd503a480cfa31f5afa09eb38f56c85c237de)
-
78704a03
by Luite Stegeman at 2026-06-10T18:17:16+05:30
Add specialized frames for small tuples
Small tuples are now returned more efficiently to the interpreter.
They use one less word of stack space and don't need manipulation
of the TSO anymore.
(cherry picked from commit e2209031734770a51f04883e5b538b562449cba1)
-
61e0bc2c
by Luite Stegeman at 2026-06-10T18:17:16+05:30
rts: add a few missing i386 relocations in the rts linker
(cherry picked from commit 04d143c02e82e9ca03eb75849959d369d07fb81a)
-
457e62c0
by Luite Stegeman at 2026-06-10T18:17:16+05:30
CodeOutput: Fix finalizers on multiple platforms
- ELF platforms: emit .fini_array section
- wasm32/Darwin: emit initializer with __cxa_atexit call
- Windows: use -Wl,--whole-archive to prevent dropping finalizer symbols
- rts linker: fix crash/assertion failure unloading objects with finalizers
fixes #27072
(cherry picked from commit 014087e7a5753687161a24a1b2bc55c7bf7273fd)
-
bf0034ff
by Ben Gamari at 2026-06-10T18:17:16+05:30
ghc-internal: Move STM utilities out of GHC.Internal.Conc.Sync
This is necessary to avoid an import cycle on Windows when importing
`GHC.Internal.Exception.Context` in `GHC.Internal.Conc.Sync`.
On the road to address #25365.
(cherry picked from commit 039bac4cf9590a6a09aa302b99fa2a0993cc0a32)
-
67dc9308
by Ben Gamari at 2026-06-10T18:17:16+05:30
base: Capture backtrace from throwSTM
Implements core-libraries-committee#297.
Fixes #25365.
(cherry picked from commit 8c389e8ce9a536da8e396a1df8c726583d0bcc14)
-
fd1e5cf5
by Ben Gamari at 2026-06-10T18:17:16+05:30
base: Annotate rethrown exceptions in catchSTM with WhileHandling
Implements core-libraries-committee#298
(cherry picked from commit e1ce1fc3ad38d192cd3b6a38cb42051f4b115e95)
-
0690216e
by fendor at 2026-06-10T18:17:16+05:30
Hide implementation details from base exception stack traces
Ensure we hide the implementation details of the exception throwing mechanisms:
* `undefined`
* `throwSTM`
* `throw`
* `throwIO`
* `error`
The `HasCallStackBacktrace` should always have a length of exactly 1,
not showing internal implementation details in the stack trace, as these
are vastly distracting to end users.
CLC proposal [#387](https://github.com/haskell/core-libraries-committee/issues/387)
(cherry picked from commit 016f79d54d482de01dd396bd9bf79f958d7c4922)
-
1709090b
by Zubin Duggal at 2026-06-10T18:17:16+05:30
fixup! Hide implementation details from base exception stack traces
-
54eec91e
by sheaf at 2026-06-10T18:17:16+05:30
Relax acceptance threshold for T10421
As seen in #27289, the 1% acceptance threshold for this text was
overly narrow, resulting in spurious test failures. This commit widens
the acceptance threshold to 2%. Fixes #27289.
(cherry picked from commit b0233814d63c2802a521dfc7dae08b1ecf494c50)
-
d4405142
by mangoiv at 2026-06-10T18:17:16+05:30
libraries/process: bump submodule to v1.6.29.0
This submodule bump resolves a segfault on macos 15.
Fixes #27144
(cherry picked from commit 277a3687c4b729e4d1ff4d4503a5673deba5eda7)
-
1c9a400f
by mangoiv at 2026-06-10T18:17:16+05:30
libraries/unix: in submodule, don't pick branch 2.7
The 2.7 branch is outdated and the module has been advanced far beyond
it anyway, so remove that line.
(cherry picked from commit 6779bb0c2d2784182465337ba5e94b7cd8810f2b)
-
a3ed39c3
by Luite Stegeman at 2026-06-10T18:17:16+05:30
Fixes for black holes
- suspend duplicate work for eager black holes
- detect eager black holes in checkBlockingQueues
- don't overwrite existing black holes even if they're not
in an eager blackhole frame
- don't deadlock on self when thunk is already blackholed
Fixes #26936
(cherry picked from commit 63ce5770da1712f0da54665d8755772bf38ba51e)
-
dfd09f11
by Tom McLaughlin at 2026-06-10T18:17:16+05:30
Event/Windows.hsc: rethrow exceptions in overlapped IO
This prevents the WinIO manager from swallowing exceptions in overlapped IO. It
was added to make WinIO support possible in the `network` library. See
https://gitlab.haskell.org/ghc/ghc/-/issues/27283.
We also bump __IO_MANAGER_WINIO__ to 2 so libraries can gate on this using CPP.
(cherry picked from commit 037a80dc65d3975adf4a35d46876850e644bc80e)
-
b1e6d7e3
by Simon Peyton Jones at 2026-06-10T18:17:16+05:30
Trim the continuation in mkDupableContWithDmds
When there are no remaining argument demands, it means the application
is bottoming. In this case, we can trim the continuation to avoid the
panic that was observed in #27261.
See Note [Trimming the continuation for bottoming functions] in
GHC.Core.Opt.Simplify.Iteration.
(cherry picked from commit 4a645683ee0bd4421a88cd6ec49b40c6046b041d)
-
dcb55823
by Zubin Duggal at 2026-06-10T18:17:16+05:30
Update to semaphore-compat 2.0.0 using v2 of the protocol
On Linux and other POSIX platforms, GHC's -jsem jobserver client now
speaks v2 of the semaphore-compat protocol, which uses Unix domain
sockets in place of POSIX named semaphores. This avoids the libc-ABI
issues that affected the old implementation. Windows is unaffected
and continues to use the v1 protocol (Win32 named semaphores); its
reported protocol version remains v1.
When GHC receives a -jsem name whose protocol version it does not
support, it emits a -Wsemaphore-version-mismatch warning and falls
back to -j<N> rather than crashing. ghc --info exposes the supported
version in a new "Semaphore version" entry so cabal-install can detect
a mismatch before invoking GHC.
Users on a cabal-install that predates the v2 update will continue to
build successfully on Linux/POSIX, but will lose the cross-process
-jsem coordination and fall back to -j<N> per GHC invocation. Users
must upgrade to a cabal-install that supports protocol v2 to recover
full parallelism.
Also fix a leak in cleanupSem (#27253): cleanupSem used to snapshot
heldTokens and release them before killing the loop, while the loop's
in-flight acquire/release children could still be mutating it.
Cleanup now runs inside the loop's own exit handler, after draining
the active child via a new activeChild TVar, so the snapshot has no
concurrent mutator.
See also:
- GHC proposal amendment: https://github.com/ghc-proposals/ghc-proposals/pull/673
- cabal-install patch: https://github.com/haskell/cabal/pull/11628
- semaphore-compat MR: https://gitlab.haskell.org/ghc/semaphore-compat/-/merge_requests/8
Bump semaphore-compat submodule to 2.0.0
Fixes #25087 and #27253
(cherry picked from commit 8db331a381ae47ad9ad5c8613f5d3e2588d5dd55)
-
de7bc8a5
by Zubin Duggal at 2026-06-10T18:17:16+05:30
Revert "Trim the continuation in mkDupableContWithDmds"
This reverts commit ad9f21431c61ccc3ddebd831286f895c46aa4f1c.
-
b0ce0465
by mangoiv at 2026-06-10T18:17:16+05:30
Trim the continuation in mkDupableContWithDmds
When there are no remaining argument demands, it means the application
is bottoming. In this case, we can trim the continuation to avoid the
panic that was observed in #27261.
See Note [Trimming the continuation for bottoming functions] in
GHC.Core.Opt.Simplify.Iteration.
This patch was rewritten to avoid pulling in a refactor.
The original patch is included in master as 4a645683
(cherry picked from commit 53f74985860b35a879bfd0dc642e7fcafffcf5e4)
-
ceb50b7c
by Zubin Duggal at 2026-06-10T18:17:16+05:30
fixup! Trim the continuation in mkDupableContWithDmds
-
59df0884
by mangoiv at 2026-06-10T18:17:16+05:30
profiling: partial backport of 2dadf3b0 to fix #27121
This backports fix and test for #27121 from 2dadf3b0 since the entirety
of the patch is not backportable without also backporting two larger
refactorings.
(cherry picked from commit 0ccecfc5b5a118c2c850f876709c21162d35d972)
-
db6bbd26
by Teo Camarasu at 2026-06-10T18:17:16+05:30
Add explicit export list to GHC.Num
Let's make clear what this module exports to allow us to easily deprecate and remove some of these in the future. Resolves https://gitlab.haskell.org/ghc/ghc/-/issues/26625
(cherry picked from commit b14bdd59202e0c32df8e5cc1923677f59c8f16e7)
-
2f255e3c
by Teo Camarasu at 2026-06-10T18:17:17+05:30
base: deprecate GHC internals in GHC.Num
Implements CLC proposal: https://github.com/haskell/core-libraries-committee/issues/360
(cherry picked from commit 75a9053d26183e71b48de4c603b04af2fa4a732d)
-
f1170d52
by Simon Peyton Jones at 2026-06-10T18:17:17+05:30
Add a deprecation warning for static forms
The accepted
GHC proposal 732: Simplify static forms
https://github.com/ghc-proposals/ghc-proposals/pull/732
needs a deprecation warning added to GHC 9.14, to warn about static
forms that mention nested free variables; see #26718.
This MR adds that warning, with test T26718 to check it.
There is no flag to switch the warning off.
(cherry picked from commit 6b7d6287c6ff4fd1b0d3aa2abfdaf73d43c4a9a0)