[Git][ghc/ghc][wip/T24382] 35 commits: Include diagnostic reason in -fdiagnostics-as-json
Ben Gamari (@bgamari)
gitlab at gitlab.haskell.org
Tue Nov 26 15:25:42 UTC 2024
Ben Gamari pushed to branch wip/T24382 at Glasgow Haskell Compiler / GHC
Commits:
831aab22 by sheaf at 2024-11-18T21:22:36-05:00
Include diagnostic reason in -fdiagnostics-as-json
This commit ensures that the -fdiagnostics-as-json output includes the
diagnostic reason. This allows the full error message produced by GHC
to be re-constructed from the JSON output.
Fixes #25403
- - - - -
3e5bfdd3 by Ben Gamari at 2024-11-18T21:23:12-05:00
rts: Introduce printIPE
This is a convenience utility for use in GDB.
- - - - -
44d909a3 by Sjoerd Visscher at 2024-11-19T14:38:24-05:00
Don't store boot locations in finder cache
Partially reverts commit fff55592a7b
Amends add(Home)ModuleToFinder so that locations for boot files are not stored in the finder cache.
Removes InstalledModule field from InstalledFound constructor since it's the same as the key that was searched for.
- - - - -
64c95292 by Sjoerd Visscher at 2024-11-19T14:38:24-05:00
Concentrate boot extension logic in Finder
With new mkHomeModLocation that takes an extra HscSource to add boot extensions if required.
- - - - -
11bad98d by ARATA Mizuki at 2024-11-19T14:39:08-05:00
Better documentation for floating-point min/max and SIMD primitives
See #25350 for floating-point min/max
Co-authored-by: sheaf <sam.derbyshire at gmail.com>
- - - - -
791a47b2 by Arnaud Spiwack at 2024-11-20T14:00:05+00:00
Add test for #25185
- - - - -
374e18e5 by Arnaud Spiwack at 2024-11-20T14:09:30+00:00
Quick look: emit the multiplicity of app heads in tcValArgs
Otherwise it's not scaled properly by the context, allowing unsound
expressions.
Fixes #25185.
- - - - -
1fc02399 by sheaf at 2024-11-20T18:11:03-05:00
x86 NCG: fix regUsageOfInstr for VMOVU & friends
This commit fixes the implementation of 'regUsageOfInstr' for vector
operations that take an 'Operand' as the destination, by ensuring that
when the destination is an address then the address should be *READ*,
and not *WRITTEN*.
Getting this wrong is a disaster, as it means the register allocator
has incorrect information, which can lead to it discard stores to
registers, segfaults ensuing.
Fixes #25486
- - - - -
7bd407a6 by Brandon Chinn at 2024-11-21T14:08:15-05:00
Fix CRLF in multiline strings (#25375)
- - - - -
7575709b by Rodrigo Mesquita at 2024-11-21T14:08:52-05:00
Improve reachability queries on ModuleGraph
Introduces `ReachabilityIndex`, an index constructed from a
`GHC.Data.Graph.Directed` `Graph` that supports fast reachability
queries (in $O(1)$). This abstract data structure is exposed from
`GHC.Data.Graph.Directed.Reachability`.
This index is constructed from the module graph nodes and cached in
`ModuleGraph`, enabling efficient reachability queries on the module
graph. Previously, we'd construct a Map of Set of ModuleGraph nodes
which used a lot of memory (`O(n^2)` in the number of nodes) and cache
that in the `ModuleGraph`. By using the reachability index we get rid of
this space leak in the module graph -- even though the index is still
quadratic in the number of modules, it is much, much more space
efficient due to its representation using an IntMap of IntSet as opposed
to the transitive closure we previously cached.
In a memory profile of MultiLayerModules with 100x100 modules, memory
usage improved from 6GB residency to 2.8GB, out of which roughly 1.8GB
are caused by a second space leak related to ModuleGraph. On the same
program, it brings compile time from 7.5s to 5.5s.
Note how we simplify `checkHomeUnitsClosed` in terms of
`isReachableMany` and by avoiding constructing a second graph with the
full transitive closure -- it suffices to answer the reachability query
on the full graph without collapsing the transitive closure completely
into nodes.
Unfortunately, solving this leak means we have to do a little bit more
work since we can no longer cache the result of turning vertex indices
into nodes. This results in a slight regression in MultiLayerModulesTH_Make,
but results in large performance and memory wins when compiling large
amounts of modules.
-------------------------
Metric Decrease:
mhu-perf
Metric Increase:
MultiLayerModulesTH_Make
-------------------------
- - - - -
bcbcdaaf by Cheng Shao at 2024-11-21T14:09:28-05:00
driver: fix hpc undefined symbol issue in TH with -fprefer-byte-code
This commit fixes an undefined symbol error in RTS linker when
attempting to compile home modules with -fhpc and
-fbyte-code-and-object-code/-fprefer-byte-code, see #25510 for
detailed description and analysis of the bug.
Also adds T25510/T25510c regression tests to test make mode/oneshot
mode of the bug.
- - - - -
970ada5a by Ben Gamari at 2024-11-22T23:32:06-05:00
gitlab-ci: Bump ci-images
For introduction of Alpine/i386 image.
Thanks to Julian for the base image.
Co-Authored-By: Julian Ospald <hasufell at hasufell.de>
- - - - -
8115abc2 by Ben Gamari at 2024-11-22T23:32:06-05:00
gitlab-ci: Add release job for i386/Alpine
As requested by Mikolaj and started by Julian.
Co-Authored-By: Julian Ospald <hasufell at hasufell.de>
- - - - -
639f0149 by Ben Gamari at 2024-11-22T23:32:06-05:00
rts/linker/Elf: Resolve _GLOBAL_OFFSET_TABLE_
- - - - -
490d4d0a by Ben Gamari at 2024-11-22T23:32:06-05:00
gitlab-ci: Mark i386 Alpine test breakages
Marks the following tests as broken on i386/Alpine:
* T22033 due to #25497
* simd009, T25062_V16, T25169, T22187_run due to #25498
- - - - -
536cdf09 by Cheng Shao at 2024-11-22T23:32:42-05:00
compiler: remove unused GHC.Linker.Loader.loadExpr
This patch removes the unused `GHC.Linker.Loader.loadExpr` function.
It was moved from `GHC.Runtime.Linker.linkExpr` in `ghc-9.0` to
`GHC.Linker.Loader.loadExpr` in `ghc-9.2`, and remain completely
unused and untested ever since. There's also no third party user of
this function to my best knowledge, so let's remove this. Anyone who
wants to write their own GHC API function to load bytecode can consult
the source code in older release branches.
- - - - -
6ee35024 by Drew Fenwick at 2024-11-22T23:33:26-05:00
Fix a non-compiling example in the type abstractions docs
This patch adds a missing Show constraint to a code example in the User Guide's type abstractions docs to fix issue #25422.
- - - - -
d1172e20 by Rodrigo Mesquita at 2024-11-22T23:34:02-05:00
Re-introduce ErrorCallWithLocation with a deprecation pragma
With the removal of the duplicate backtrace, part of CLC proposal #285,
the constructor `ErrorCallWithLocation` was removed from base.
This commit re-introduces it with a deprecation.
- - - - -
1187a60a by Ben Gamari at 2024-11-22T23:34:39-05:00
testsuite: Skip tests requiring Hadrian deps in out-of-tree testsuite runs
Some testsuite tests require specific tools (e.g. `check-ppr` and
`check-exact`) beyond those shipped in the binary distribution. Skip
these tests.
Fixes #13897.
- - - - -
c37d7a2e by Ben Gamari at 2024-11-22T23:34:39-05:00
testsuite: Declare exactprint tests' dependency on check-exact
- - - - -
454ce957 by Ben Gamari at 2024-11-22T23:35:15-05:00
ghc-internal: Fix a few cases of missing Haddock markup
- - - - -
a249649b by Ben Gamari at 2024-11-22T23:35:51-05:00
testsuite/GHCiPrimCall : Add missing Makefile includes
- - - - -
a021a493 by Ben Gamari at 2024-11-22T23:35:51-05:00
testsuite/IpeStats: Use Make rather than shell interpolation
- - - - -
6e1fbda7 by Ben Gamari at 2024-11-25T03:55:44-05:00
hadrian-ghci-multi: Pass -this-package-name in unit response files
As noted in #25509, the `-this-package-name` must be passed for each
package to ensure that GHC can response references to the packages'
exposed modules via package-qualified imports. Fix this.
Closes #25509.
- - - - -
a05e4a9b by Simon Hengel at 2024-11-25T03:56:33-05:00
Refactoring: Use `OnOff` more consistently for `Extension`
- - - - -
7536181d by Matthew Pickering at 2024-11-25T14:00:07-05:00
driver: Always link against "base" package when one shot linking
The default value for base-unit-id is stored in the settings file.
At install time, this can be set by using the BASE_UNIT_ID environment
variable.
At runtime, the value can be set by `-base-unit-id` flag.
For whether all this is a good idea, see #25382
Fixes #25382
- - - - -
7f90f319 by Andreas Klebinger at 2024-11-25T14:00:44-05:00
Compacting GC: Handle black holes in large objects.
As #14497 showed black holes can appear inside large objects when
we capture a computation and later blackhole it like we do for AP_STACK
closures.
Fixes #24791
- - - - -
291388e1 by Cheng Shao at 2024-11-25T14:01:19-05:00
ci: minor nix-in-docker improvements
This patch makes some minor improvements re nix-in-docker logic in the
ci configuration:
- Update `nixos/nix` to the latest version
- Apply $CPUS to `cores`/`max-jobs` to avoid oversubscribing while
allowing a reasonable degree of parallelism
- Remove redundant `--extra-experimental-features nix-command` in
later `nix shell` invocations, it's already configured in
`/etc/nix/nix.conf`
- - - - -
e684c406 by Cheng Shao at 2024-11-25T14:01:57-05:00
ci: avoid depending on stack job for test-bootstrap jobs
This patch makes test-bootstrap related ci jobs only depend on
hadrian-ghc-in-ghci job to finish, consistent with other jobs in the
full-build stage generated by gen_ci.hs. This allows the jobs to be
spawned earlier and improve overall pipeline parallelism.
- - - - -
caaf5388 by Simon Hengel at 2024-11-25T14:02:41-05:00
Refactoring: Remove `pSupportedExts` from `ParserOpts`
This is never used for lexing / parsing. It is only used by
`GHC.Parser.Header.getOptions`.
- - - - -
41f8365c by Arnaud Spiwack at 2024-11-25T14:03:23-05:00
Add test for #25515
- - - - -
9279619f by Arnaud Spiwack at 2024-11-25T14:03:23-05:00
Desugar record notation with correct multiplicities
Simply uses the multiplicity as stored in the field. As I'm writing
this commit, the only possible multiplicity is 1, but !13525 is
changing this. It's actually easier to take !13525 into account.
Fixes #25515.
- - - - -
fcc3ae6e by Andreas Klebinger at 2024-11-26T08:24:58-05:00
Clarify INLINE unfolding optimization docs.
Fixes #24660
- - - - -
88c4fe1d by Cheng Shao at 2024-11-26T08:25:34-05:00
rts: remove -Wl,-U,___darwin_check_fd_set_overflow hack
This patch bumps macOS minimum SDK version to 11.0 for x86_64-darwin
to align it with aarch64-darwin. This allows us to get rid of the
horrible -Wl,-U,___darwin_check_fd_set_overflow hack, which is causing
linker warnings and testsuite failures on macOS 15. Fixes #25504.
- - - - -
9ad346ec by Ben Gamari at 2024-11-26T10:25:14-05:00
hadrian: Bump directory bound to >=1.3.9
Earlier versions of `directory` are racy on Windows due to #24382.
Also includes necessary Hadrian bootstrap plan bump.
Fixes #24382.
- - - - -
30 changed files:
- .gitattributes
- .gitlab-ci.yml
- .gitlab/ci.sh
- .gitlab/generate-ci/gen_ci.hs
- .gitlab/hello.hs
- .gitlab/jobs.yaml
- compiler/GHC/Builtin/primops.txt.pp
- compiler/GHC/CmmToAsm/Format.hs
- compiler/GHC/CmmToAsm/X86/Instr.hs
- compiler/GHC/Data/Graph/Directed.hs
- + compiler/GHC/Data/Graph/Directed/Internal.hs
- + compiler/GHC/Data/Graph/Directed/Reachability.hs
- compiler/GHC/Driver/Backpack.hs
- compiler/GHC/Driver/Config/Parser.hs
- compiler/GHC/Driver/Config/StgToCmm.hs
- compiler/GHC/Driver/DynFlags.hs
- compiler/GHC/Driver/Flags.hs
- compiler/GHC/Driver/Hooks.hs
- compiler/GHC/Driver/Main.hs
- compiler/GHC/Driver/Make.hs
- compiler/GHC/Driver/MakeFile.hs
- compiler/GHC/Driver/Phases.hs
- compiler/GHC/Driver/Pipeline/Execute.hs
- compiler/GHC/Driver/Session.hs
- compiler/GHC/HsToCore/Coverage.hs
- compiler/GHC/Iface/Load.hs
- compiler/GHC/Iface/Tidy.hs
- compiler/GHC/Linker/Deps.hs
- compiler/GHC/Linker/Loader.hs
- compiler/GHC/Parser/HaddockLex.x
The diff was not included because it is too large.
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/e9ac7c65cd57d3d4e1c91f161feb20451971e17e...9ad346ec8bfa22a2843f8d2c8d998133d0715702
--
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/e9ac7c65cd57d3d4e1c91f161feb20451971e17e...9ad346ec8bfa22a2843f8d2c8d998133d0715702
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/20241126/a3340c04/attachment-0001.html>
More information about the ghc-commits
mailing list