[Git][ghc/ghc][wip/int-index/since98] 22 commits: Separate core inlining logic from `Unfolding` type.
Vladislav Zavialov (@int-index)
gitlab at gitlab.haskell.org
Wed Jan 18 09:38:58 UTC 2023
Vladislav Zavialov pushed to branch wip/int-index/since98 at Glasgow Haskell Compiler / GHC
Commits:
7a9a1042 by Andreas Klebinger at 2023-01-16T20:48:19-05:00
Separate core inlining logic from `Unfolding` type.
This seems like a good idea either way, but is mostly motivated by a
patch where this avoids a module loop.
- - - - -
33b58f77 by sheaf at 2023-01-16T20:48:57-05:00
Hadrian: generalise &%> to avoid warnings
This patch introduces a more general version of &%> that works
with general traversable shapes, instead of lists. This allows us
to pass along the information that the length of the list of filepaths
passed to the function exactly matches the length of the input list
of filepath patterns, avoiding pattern match warnings.
Fixes #22430
- - - - -
8c7a991c by Andreas Klebinger at 2023-01-16T20:49:34-05:00
Add regression test for #22611.
A case were a function used to fail to specialize, but now does.
- - - - -
6abea760 by Andreas Klebinger at 2023-01-16T20:50:10-05:00
Mark maximumBy/minimumBy as INLINE.
The RHS was too large to inline which often prevented the overhead of the Maybe
from being optimized away. By marking it as INLINE we can eliminate the
overhead of both the maybe and are able to unpack the accumulator when
possible.
Fixes #22609
- - - - -
99d151bb by Matthew Pickering at 2023-01-16T20:50:50-05:00
ci: Bump CACHE_REV so that ghc-9.6 branch and HEAD have different caches
Having the same CACHE_REV on both branches leads to issues where the
darwin toolchain is different on ghc-9.6 and HEAD which leads to long
darwin build times.
In general we should ensure that each branch has a different CACHE_REV.
- - - - -
6a5845fb by Matthew Pickering at 2023-01-16T20:51:25-05:00
ci: Change owner of files in source-tarball job
This fixes errors of the form:
```
fatal: detected dubious ownership in repository at '/builds/ghc/ghc'
To add an exception for this directory, call:
git config --global --add safe.directory /builds/ghc/ghc
inferred 9.7.20230113
checking for GHC Git commit id... fatal: detected dubious ownership in repository at '/builds/ghc/ghc'
To add an exception for this directory, call:
git config --global --add safe.directory /builds/ghc/ghc
```
- - - - -
4afb952c by Matthew Pickering at 2023-01-16T20:51:25-05:00
ci: Don't build aarch64-deb10-llvm job on release pipelines
Closes #22721
- - - - -
8039feb9 by Matthew Pickering at 2023-01-16T20:51:25-05:00
ci: Change owner of files in test-bootstrap job
- - - - -
0b358d0c by Matthew Pickering at 2023-01-16T20:51:25-05:00
rel_eng: Add release engineering scripts into ghc tree
It is better to keep these scripts in the tree as they depend on the CI
configuration and so on. By keeping them in tree we can keep them
up-to-date as the CI config changes and also makes it easier to backport
changes to the release script between release branches in future.
The final motivation is that it makes generating GHCUp metadata
possible.
- - - - -
28cb2ed0 by Matthew Pickering at 2023-01-16T20:51:25-05:00
ci: Don't use complicated image or clone in not-interruptible job
This job exists only for the meta-reason of not allowing nightly
pipelines to be cancelled. It was taking two minutes to run as in order
to run "true" we would also clone the whole GHC repo.
- - - - -
eeea59bb by Matthew Pickering at 2023-01-16T20:51:26-05:00
Add scripts to generate ghcup metadata on nightly and release pipelines
1. A python script in .gitlab/rel_eng/mk-ghcup-metadata which generates
suitable metadata for consumption by GHCUp for the relevant
pipelines.
- The script generates the metadata just as the ghcup maintainers
want, without taking into account platform/library combinations. It
is updated manually when the mapping changes.
- The script downloads the bindists which ghcup wants to distribute,
calculates the hash and generates the yaml in the correct structure.
- The script is documented in the .gitlab/rel_eng/mk-ghcup-metadata/README.mk file
1a. The script requires us to understand the mapping from platform ->
job. To choose the preferred bindist for each platform the
.gitlab/gen_ci.hs script is modified to allow outputting a metadata
file which answers the question about which job produces the
bindist which we want to distribute to users for a specific
platform.
2. Pipelines to run on nightly and release jobs to generate metadata
- ghcup-metadata-nightly: Generates metadata which points directly to
artifacts in the nightly job.
- ghcup-metadata-release: Generates metadata suitable for inclusion
directly in ghcup by pointing to the downloads folder where the
bindist will be uploaded to.
2a. Trigger jobs which test the generated metadata in the downstream
`ghccup-ci` repo. See that repo for documentation about what is
tested and how but essentially we test in a variety of clean images
that ghcup can download and install the bindists we say exist in our
metadata.
- - - - -
97bd4d8c by Bodigrim at 2023-01-16T20:52:04-05:00
Bump submodule parsec to 3.1.16.1
- - - - -
97ac8230 by Alan Zimmerman at 2023-01-16T20:52:39-05:00
EPA: Add annotation for 'type' in DataDecl
Closes #22765
- - - - -
dbbab95d by Ben Gamari at 2023-01-17T06:36:06-05:00
compiler: Small optimisation of assertM
In #22739 @AndreasK noticed that assertM performed the action to compute
the asserted predicate regardless of whether DEBUG is enabled. This is
inconsistent with the other assertion operations and general convention.
Fix this.
Closes #22739.
- - - - -
fc02f3bb by Viktor Dukhovni at 2023-01-17T06:36:47-05:00
Avoid unnecessary printf warnings in EventLog.c
Fixes #22778
- - - - -
003b6d44 by Simon Peyton Jones at 2023-01-17T16:33:05-05:00
Document the semantics of pattern bindings a bit better
This MR is in response to the discussion on #22719
- - - - -
f4d50baf by Vladislav Zavialov at 2023-01-17T16:33:41-05:00
Hadrian: fix warnings (#22783)
This change fixes the following warnings when building Hadrian:
src/Hadrian/Expression.hs:38:10: warning: [-Wredundant-constraints]
src/Hadrian/Expression.hs:84:13: warning: [-Wtype-equality-requires-operators]
src/Hadrian/Expression.hs:84:21: warning: [-Wtype-equality-requires-operators]
src/Hadrian/Haskell/Cabal/Parse.hs:67:1: warning: [-Wunused-imports]
- - - - -
06036d93 by Sylvain Henry at 2023-01-18T01:55:10-05:00
testsuite: req_smp --> req_target_smp, req_ghc_smp
See #22630 and !9552
This commit:
- splits req_smp into req_target_smp and req_ghc_smp
- changes the testsuite driver to calculate req_ghc_smp
- changes a handful of tests to use req_target_smp instead of req_smp
- changes a handful of tests to use req_host_smp when needed
The problem:
- the problem this solves is the ambiguity surrounding req_smp
- on master req_smp was used to express the constraint that the program
being compiled supports smp _and_ that the host RTS (i.e., the RTS used
to compile the program) supported smp. Normally that is fine, but in
cross compilation this is not always the case as was discovered in #22630.
The solution:
- Differentiate the two constraints:
- use req_target_smp to say the RTS the compiled program is linked
with (and the platform) supports smp
- use req_host_smp to say the RTS the host is linked with supports smp
WIP: fix req_smp (target vs ghc)
add flag to separate bootstrapper
split req_smp -> req_target_smp and req_ghc_smp
update tests smp flags
cleanup and add some docstrings
only set ghc_with_smp to bootstrapper on S1 or CC
Only set ghc_with_smp to bootstrapperWithSMP of when testing stage 1
and cross compiling
test the RTS in config/ghc not hadrian
re-add ghc_with_smp
fix and align req names
fix T11760 to use req_host_smp
test the rts directly, avoid python 3.5 limitation
test the compiler in a try block
align out of tree and in tree withSMP flags
mark failing tests as host req smp
testsuite: req_host_smp --> req_ghc_smp
Fix ghc vs host, fix ghc_with_smp leftover
- - - - -
ee9b78aa by Krzysztof Gogolewski at 2023-01-18T01:55:45-05:00
Use -Wdefault when running Python testdriver (#22727)
- - - - -
e9c0537c by Vladislav Zavialov at 2023-01-18T01:56:22-05:00
Enable -Wstar-is-type by default (#22759)
Following the plan in GHC Proposal #143 "Remove the * kind syntax",
which states:
In the next release (or 3 years in), enable -fwarn-star-is-type by default.
The "next release" happens to be 9.6.1
I also moved the T21583 test case from should_fail to should_compile,
because the only reason it was failing was -Werror=compat in our test
suite configuration.
- - - - -
4efee43d by Ryan Scott at 2023-01-18T01:56:59-05:00
Add missing parenthesizeHsType in cvtSigTypeKind
We need to ensure that the output of `cvtSigTypeKind` is parenthesized (at
precedence `sigPrec`) so that any type signatures with an outermost, explicit
kind signature can parse correctly.
Fixes #22784.
- - - - -
7c6fb372 by Vladislav Zavialov at 2023-01-18T12:37:19+03:00
Set "since: 9.8" for TypeAbstractions and -Wterm-variable-capture
These flags did not make it into the 9.6 release series,
so the "since" annotations must be corrected.
- - - - -
30 changed files:
- .gitlab-ci.yml
- .gitlab/gen_ci.hs
- + .gitlab/generate_job_metadata
- .gitlab/generate_jobs
- .gitlab/jobs.yaml
- + .gitlab/rel_eng/default.nix
- + .gitlab/rel_eng/fetch-gitlab-artifacts/.gitignore
- + .gitlab/rel_eng/fetch-gitlab-artifacts/README.mkd
- + .gitlab/rel_eng/fetch-gitlab-artifacts/default.nix
- + .gitlab/rel_eng/fetch-gitlab-artifacts/fetch_gitlab.py
- + .gitlab/rel_eng/fetch-gitlab-artifacts/setup.py
- + .gitlab/rel_eng/mk-ghcup-metadata/.gitignore
- + .gitlab/rel_eng/mk-ghcup-metadata/README.mkd
- + .gitlab/rel_eng/mk-ghcup-metadata/default.nix
- + .gitlab/rel_eng/mk-ghcup-metadata/mk_ghcup_metadata.py
- + .gitlab/rel_eng/mk-ghcup-metadata/setup.py
- + .gitlab/rel_eng/nix/sources.json
- + .gitlab/rel_eng/nix/sources.nix
- + .gitlab/rel_eng/upload.sh
- .gitlab/upload_ghc_libs.py → .gitlab/rel_eng/upload_ghc_libs.py
- compiler/GHC/Core/Opt/LiberateCase.hs
- + compiler/GHC/Core/Opt/Simplify/Inline.hs
- compiler/GHC/Core/Opt/Simplify/Iteration.hs
- compiler/GHC/Core/Opt/Simplify/Utils.hs
- compiler/GHC/Core/Opt/SpecConstr.hs
- compiler/GHC/Core/Unfold.hs
- compiler/GHC/Driver/Flags.hs
- compiler/GHC/Hs/Utils.hs
- compiler/GHC/HsToCore/Expr.hs
- compiler/GHC/Parser.y
The diff was not included because it is too large.
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/8bf197a1e296773b730436a7fce283361673a0c3...7c6fb3722e4544936654fbbe528cb99554c55e69
--
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/8bf197a1e296773b730436a7fce283361673a0c3...7c6fb3722e4544936654fbbe528cb99554c55e69
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/20230118/9af20d9a/attachment-0001.html>
More information about the ghc-commits
mailing list