Commits on Source (69)
-
This seems like a good idea either way, but is mostly motivated by a patch where this avoids a module loop.
7a9a1042 -
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
33b58f77 -
A case were a function used to fail to specialize, but now does.
8c7a991c -
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
6abea760 -
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.
99d151bb -
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 ```
6a5845fb -
Closes #22721
4afb952c -
8039feb9
-
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.
0b358d0c -
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.
28cb2ed0 -
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.
eeea59bb -
Closes #22765
97ac8230 -
This MR is in response to the discussion on #22719
003b6d44 -
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]
f4d50baf -
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
06036d93 -
ee9b78aa
-
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.
e9c0537c -
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.
4efee43d -
It turns out that gmp 6.2.1 uses the platform-reserved `x18` register on AArch64/Darwin. This was fixed in upstream changeset 18164:5f32dbc41afc, which was merged in 2020. Here I backport this patch although I do hope that a new release is forthcoming soon. Bumps gmp-tarballs submodule. Fixes #22497.
f891a442 -
This backports the upstream fix for CVE-2021-43618, fixing #22789.
b13c6ea5 -
Corrects a typo in !9647. Otherwise T18623 will still fail on darwin and stall other people's work.
c45a5fff -
This adds support for calling Cmm code from bytecode using the native calling convention, allowing modules that use `foreign import prim` to be loaded and debugged in GHCi. This patch introduces a new `PRIMCALL` bytecode instruction and a helper stack frame `stg_primcall`. The code is based on the existing functionality for dealing with unboxed tuples in bytecode, which has been generalised to handle arbitrary calls. Fixes #22051
b4c14c4b -
This adds `-Werror=<group>` and `-fwarn-<group>` flags for warning groups as well as individual warnings. Previously these were defined on an ad hoc basis so for example we had `-Werror=compat` but not `-Werror=unused-binds`, whereas we had `-fwarn-unused-binds` but not `-fwarn-compat`. Fixes #22182.
d0a63ef8 -
7ed1b8ef
-
5389681e
-
ab0d5cda
-
Currently it doesn't do much anything, we are just trying to introduce it without breaking the build. Later, we will move functionality from the top-level configure script over to it. We need to bump Cabal for https://github.com/haskell/cabal/pull/8649; to facilitate and existing hack of skipping some configure checks for the RTS we now need to skip just *part* not *all* of the "post configure" hook, as running the configure script (which we definitely want to do) is also implemented as part of the "post configure" hook. But doing this requires exposing functionality that wasn't exposed before.
eb5a6b91 -
In #22764 a user noticed that a program implementing a simple atomic counter via an STRef regressed significantly due to the introduction of necessary atomic operations in the MutVar# primops (#22468). This regression was caused by a bug in the NCG, which emitted an unnecessary MFENCE instruction for a release-ordered atomic write. MFENCE is rather only needed to achieve sequentially consistent ordering. Fixes #22764.
f058e367 -
Problem: In 2463df2f, the Solo data constructor was renamed to MkSolo, and Solo was turned into a pattern synonym for backwards compatibility. Since pattern synonyms can not be promoted, the old code that pretty-printed promoted single-element tuples started producing ill-typed code: t :: Proxy ('Solo Int) This fails with "Pattern synonym ‘Solo’ used as a type" The solution is to track the distinction between type constructors and data constructors more carefully when printing single-element tuples.
14b5982a -
The hi_core flavour transformer enables -fwrite-if-simplified-core for stage1 libraries, which emit core into interface files to make it possible to restart code generation. Building boot libs with it makes it easier to use GHC API to prototype experimental backends that needs core/stg at link time.
1fe806d3 -
317cad26
-
Addresses #22268.
658f4446 -
These flags did not make it into the 9.6 release series, so the "since" annotations must be corrected.
a83ec778 -
To be able to capture string literals with possible escape codes as labels. Close #22771
fec7c2ea -
Updates `text` and `exceptions` submodules for bounds bumps. Addresses #22767.
3efd1e99 -
When building in-tree GMP for wasm32, disable its alloca usage, since it may potentially cause stack overflow (e.g. #22602).
0900b584 -
Includes a critical fix for wasm32, see https://github.com/haskell/process/pull/272 for details. Also changes the existing cross test to include process stuff and avoid future regression here.
db0f1bfd -
9222b167
-
This has been removed from the downstream metadata.
9a9bec57 -
runtimeRepLevity_maybe was panicing unnecessarily; and the error printing code made use of the case when it should return Nothing rather than panicing. For some bizarre reason perf/compiler/T21839r shows a 10% bump in runtime peak-megagbytes-used, on a single architecture (alpine). See !9753 for commentary, but I'm going to accept it. Metric Increase: T21839r
82884ce0 -
...the testsuite doesn't handle this properly since it also collects run-time metrics. Compile-time metrics for this test are already tracked via T21839c. Metric Decrease: T21839r
eee3bf05 -
The key part of this change is to store a UnitId in the `UsageHomeModule` and `UsageHomeModuleInterface`. * Fine-grained dependency tracking is used if the dependency comes from any home unit. * We actually look up the right module when checking whether we need to recompile in the `UsageHomeModuleInterface` case. These scenarios are both checked by the new tests ( multipleHomeUnits_recomp and multipleHomeUnits_recomp_th ) Fixes #22675
1d1dd3fb -
This fixes a spurious warning in -Wmissing-home-modules. This is a simple oversight where when looking for the target in the first place we augment the search by the -working-directory flag but then fail to do so when checking this warning. Fixes #22676
7bfb30f9 -
The `pruneCache` function assumes that the list of `CachedInfo` all have unique `ModuleName`, this is not true: * In normal compilation, the same module name can appear for a file and it's boot file. * In multiple home unit compilation the same ModuleName can appear in different units The fix is to use a `NodeKey` as the actual key for the interfaces which includes `ModuleName`, `IsBoot` and `UnitId`. Fixes #22677
69500dd4 -
In interactive mode we don't produce any linkables for hs-boot files. So we also need to not going looking for them when we check to see if we have all the right objects needed for recompilation. Ticket #22669
336b2b1c -
We should not be producing object files when in interactive mode but we still produced the dummy o-boot files. These never made it into a `Linkable` but then confused the recompilation checker. Fixes #22669
6469fea7 -
Currently the driver diagnostics don't give any indication about which unit they correspond to. For example `-Wmissing-home-modules` can fire multiple times for each different home unit and gives no indication about which unit it's actually reporting about. Perhaps a longer term fix is to generalise the providence information away from a SrcSpan so that these kind of whole project errors can be reported with an accurate provenance. For now we can just include the `UnitId` in the error message. Fixes #22678
06cc0a95 -
Multiple units can refer to the same files without any problem. Just another assumption which needs to be updated when we may have multiple home units. However, there is the invariant that within each unit each file only maps to one module, so as long as we also key the cache by UnitId then we are all good. This led to some confusing behaviour in GHCi when reloading, multipleHomeUnits_shared distils the essence of what can go wrong. Fixes #22679
4fe9eaff -
In order to preserve existing behaviour it's important to look within the current component before consideirng a module might come from an external component. This already happened by accident in `downsweep`, (because roots are used to repopulated the cache) but in the `Finder` the logic was the wrong way around. Fixes #22680 ------------------------- Metric Decrease: MultiComponentModules MultiComponentModulesRecomp -------------------------p
ada29f5c -
This is helpful when debugging multiple component issues.
be701cc6 -
Lint was checking for duplicate external names by calling removeDups, which needs a comparison function that is passed to Data.List.sortBy. But the comparison was not a valid ordering - it returned LT if one of the names was not external. For example, the previous implementation won't find a duplicate in [M.x, y, M.x]. Instead, we filter out non-external names before looking for duplicates.
34d2d463 -
We used to print the offset value to a platform word sized integer. This is incorrect when the offset is negative (e.g. output of cmm constant folding) and the register is 64-bit but on a 32-bit target, and may lead to incorrect runtime result (e.g. #22607). The fix is simple: just treat it as a proper MO_Add, with the correct width info inferred from the register itself. Metric Increase: T12707 T13379 T4801 T5321FD T5321Fun
d151546e -
e5383a29
-
Fixes #22816.
1957eda1 -
Removes references to make. Fixes #22480
30972827 -
In the wasm NCG, we used to compile MO_F_Neg to 0.0-x. It was an oversight, there actually exists f32.neg/f64.neg opcodes in the wasm spec and those should be used instead! The old behavior almost works, expect when GHC compiles the -0.0 literal, which will incorrectly become 0.0.
bc038c3b -
David authoredd5fc7f40
-
David authored1dc40cf3
-
David authoredb681cf64
-
David authored72b455a5
Showing
- .gitlab-ci.yml 142 additions, 3 deletions.gitlab-ci.yml
- .gitlab/gen_ci.hs 124 additions, 26 deletions.gitlab/gen_ci.hs
- .gitlab/generate_job_metadata 5 additions, 0 deletions.gitlab/generate_job_metadata
- .gitlab/generate_jobs 1 addition, 1 deletion.gitlab/generate_jobs
- .gitlab/hello.hs 3 additions, 1 deletion.gitlab/hello.hs
- .gitlab/jobs.yaml 121 additions, 60 deletions.gitlab/jobs.yaml
- .gitlab/rel_eng/default.nix 56 additions, 0 deletions.gitlab/rel_eng/default.nix
- .gitlab/rel_eng/fetch-gitlab-artifacts/.gitignore 3 additions, 0 deletions.gitlab/rel_eng/fetch-gitlab-artifacts/.gitignore
- .gitlab/rel_eng/fetch-gitlab-artifacts/README.mkd 23 additions, 0 deletions.gitlab/rel_eng/fetch-gitlab-artifacts/README.mkd
- .gitlab/rel_eng/fetch-gitlab-artifacts/default.nix 13 additions, 0 deletions.gitlab/rel_eng/fetch-gitlab-artifacts/default.nix
- .gitlab/rel_eng/fetch-gitlab-artifacts/fetch_gitlab.py 145 additions, 0 deletions.gitlab/rel_eng/fetch-gitlab-artifacts/fetch_gitlab.py
- .gitlab/rel_eng/fetch-gitlab-artifacts/setup.py 14 additions, 0 deletions.gitlab/rel_eng/fetch-gitlab-artifacts/setup.py
- .gitlab/rel_eng/mk-ghcup-metadata/.gitignore 3 additions, 0 deletions.gitlab/rel_eng/mk-ghcup-metadata/.gitignore
- .gitlab/rel_eng/mk-ghcup-metadata/README.mkd 56 additions, 0 deletions.gitlab/rel_eng/mk-ghcup-metadata/README.mkd
- .gitlab/rel_eng/mk-ghcup-metadata/default.nix 13 additions, 0 deletions.gitlab/rel_eng/mk-ghcup-metadata/default.nix
- .gitlab/rel_eng/mk-ghcup-metadata/mk_ghcup_metadata.py 273 additions, 0 deletions.gitlab/rel_eng/mk-ghcup-metadata/mk_ghcup_metadata.py
- .gitlab/rel_eng/mk-ghcup-metadata/setup.py 14 additions, 0 deletions.gitlab/rel_eng/mk-ghcup-metadata/setup.py
- .gitlab/rel_eng/nix/sources.json 68 additions, 0 deletions.gitlab/rel_eng/nix/sources.json
- .gitlab/rel_eng/nix/sources.nix 194 additions, 0 deletions.gitlab/rel_eng/nix/sources.nix
- .gitlab/rel_eng/upload.sh 250 additions, 0 deletions.gitlab/rel_eng/upload.sh
.gitlab/generate_job_metadata
0 → 100755
.gitlab/rel_eng/default.nix
0 → 100644
.gitlab/rel_eng/mk-ghcup-metadata/.gitignore
0 → 100644
.gitlab/rel_eng/mk-ghcup-metadata/README.mkd
0 → 100644
.gitlab/rel_eng/mk-ghcup-metadata/setup.py
0 → 100644
.gitlab/rel_eng/nix/sources.json
0 → 100644
.gitlab/rel_eng/nix/sources.nix
0 → 100644
.gitlab/rel_eng/upload.sh
0 → 100755