Marge Bot pushed to branch wip/marge_bot_batch_merge_job at Glasgow Haskell Compiler / GHC Commits: 38d421fb by Sylvain Henry at 2026-11-16T16:02:22-05:00 CoreMap: look up a non-recursive let with the key order of the store xtE stored a `Let (NonRec b r) e` with the body e as the first key and the right-hand side r as the second key. lkE used the opposite order. When a trie level holds one entry, GenMap compares the full keys with (==), and the difference has no effect. When a trie level holds two entries, a lookup of an expression with a non-recursive let fails. A later insert of an equal expression then overwrites the first entry. Now xtE stores the key in the order that lkE uses. Effects of the bug: CSE did not share identical bindings when a module had two different bindings that hold a non-recursive let or join point (#27892). The pattern-match checker gave different representatives to equal guard or view expressions, and thus reported spurious non-exhaustive matches. Fixes #27892. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> - - - - - fa5bc4c0 by Sylvain Henry at 2026-11-16T16:02:22-05:00 CoreMap: ignore the multiplicities of binders BndrMap keyed a binder on its type and on its multiplicity, and eqDeBruijnExpr compared the multiplicities of lambda binders. But the multiplicity of a let binder has no meaning (Note [Multiplicity of let binders] in GHC.Types.Var), and Core-to-core passes do not keep the multiplicities of lambda binders correct (Note [Linting linearity] in GHC.Core.Lint). Thus the trie separated terms that are equal. The key-order bug fixed in the previous commit hid this bug. With that fix, the pattern-match checker gave different representatives to two equal view expressions when one let came from the source and the other let came from the beta-reduction of a linear lambda. Now BndrMap is TypeMapG again, as before the linear types commit, and eqDeBruijnExpr ignores the multiplicities of lambda binders. The haddocks of CoreMap and eqCoreExpr state this contract. Fixes #28095. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> - - - - - fa6b8c9e by Simon Peyton Jones at 2026-11-16T16:03:04-05:00 Swap visibilities in mkSymCo As #28123 showed, `mkSymCo` was failing to swap visibility flags in `ForAllCo`. Fixing that in turn showed that the change to `mkEtaForAllMCo` that allegedly fixed #27557 was utterly wrong, and should simply be un-done. I have added some comments to document the invariants. - - - - - e53383b7 by fendor at 2026-11-16T16:35:03-05:00 Add support for streaming `ghc -M` to stdout Adds the flags `-dep-json-stdout` and `-dep-makefile-stdout` which streams dependency information line-by-line to stdout. Each dependency generation can be redirected to separate outputs. Providing any extra `-dep-{json,makefile}[-stdout]` disables the default generation of the `Makefile` file. Allows consumers to start processing the dependency information as it comes in and not waiting for the dependency generation to finish. `DepStream` abstracts over the possible output handles, which is either a file or the stdout handle. Writing to a file requires temporary file paths, thus `DepStream` must provide a way to perform clean up when dependency processing finished or when an error is thrown for any reason. We further decouple the rendering and writing of the result from the dependency generation, localising side effects and making the code slightly more readable. The testsuite now also handles `ghc -M` writing to stdout. We add a test for each combination of writing to stdout and file, except for writing both makefile and json. While it probably works, is really undefined behaviour. Closes #27937 - - - - - 0843ea56 by Sylvain Henry at 2026-11-16T16:35:08-05:00 Link the on-demand iserv without --gc-sections GHC links an iserv program each time a session needs the external interpreter. The link is static, against the ghci library and the boot libraries. Like all executable links, it passed -Wl,--gc-sections to a GNU linker. On libraries built with -split-sections (the release bindists), the section garbage collection of ld.bfd is the largest part of that link: with binutils 2.45, the link takes 3 times longer with --gc-sections than without. The program is temporary and its size is not important. Thus the iserv link does not use --gc-sections. Other executable links do not change. In CI, each ext-interp or ghci-ext test takes 12 to 18 times longer in the x86_64-linux-fedora43-release test job (split sections) than in the x86_64-linux-deb13-validate test job (no split sections) on the same runner, while a normal-way test takes the same time in both. This link is most of that difference. See Note [No --gc-sections for the on-demand iserv] in GHC.Runtime.Interpreter.C. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> - - - - - 355d9474 by mangoiv at 2026-11-16T16:35:09-05:00 ci: make tests-primops run on marge CI test primops dispatch was disabled on the *full-ci group label to avoid dispatching for some of its configs but wasn't reenabled for marge ci runs which it ought to run Fixes #27765 - - - - - 14d34c7c by David Eichmann at 2026-11-16T16:35:10-05:00 test driver refactor: replace `.format(**locals())` with f-string - - - - - 35 changed files: - .gitlab-ci.yml - + changelog.d/27892 - + changelog.d/T28123 - + changelog.d/iserv-no-gc-sections.md - + changelog.d/make-depends-streaming-output - compiler/GHC/Core/Map/Expr.hs - compiler/GHC/Core/Map/Type.hs - compiler/GHC/Core/Opt/Arity.hs - compiler/GHC/Core/TyCo/Make.hs - compiler/GHC/Driver/DynFlags.hs - compiler/GHC/Driver/MakeFile.hs - compiler/GHC/Driver/Session.hs - compiler/GHC/Linker/Executable.hs - compiler/GHC/Runtime/Interpreter/C.hs - docs/users_guide/separate_compilation.rst - testsuite/driver/my_typing.py - testsuite/driver/testglobals.py - testsuite/driver/testlib.py - testsuite/tests/driver/mkdepend/all.T - testsuite/tests/driver/mkdepend/mkdepend_mhu01.dep-json → testsuite/tests/driver/mkdepend/mkdepend_mhu01a.dep-json - testsuite/tests/driver/mkdepend/mkdepend_mhu01.dep-makefile → testsuite/tests/driver/mkdepend/mkdepend_mhu01a.dep-makefile - + testsuite/tests/driver/mkdepend/mkdepend_mhu01b.stderr - + testsuite/tests/driver/mkdepend/mkdepend_mhu01c.stderr - + testsuite/tests/driver/mkdepend/mkdepend_mhu01d.dep-makefile - + testsuite/tests/driver/mkdepend/mkdepend_mhu01d.stderr - + testsuite/tests/pmcheck/should_compile/T27892a.hs - + testsuite/tests/pmcheck/should_compile/T28095.hs - testsuite/tests/pmcheck/should_compile/all.T - + testsuite/tests/simplCore/should_compile/T27892.hs - + testsuite/tests/simplCore/should_compile/T27892.stderr - + testsuite/tests/simplCore/should_compile/T28095a.hs - + testsuite/tests/simplCore/should_compile/T28095a.stderr - testsuite/tests/simplCore/should_compile/all.T - + testsuite/tests/vdq-rta/should_compile/T28123.hs - testsuite/tests/vdq-rta/should_compile/all.T The diff was not included because it is too large. View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/3aebf0de64f8bea14942934be9b86a0... -- View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/3aebf0de64f8bea14942934be9b86a0... You're receiving this email because of your account on gitlab.haskell.org. Manage all notifications: https://gitlab.haskell.org/-/profile/notifications | Help: https://gitlab.haskell.org/help