[Git][ghc/ghc][wip/int-index/t2t-expr] 131 commits: Remove ScopedTypeVariables => TypeAbstractions

Vladislav Zavialov (@int-index) gitlab at gitlab.haskell.org
Fri Sep 29 14:04:28 UTC 2023



Vladislav Zavialov pushed to branch wip/int-index/t2t-expr at Glasgow Haskell Compiler / GHC


Commits:
9eecdf33 by sheaf at 2023-08-28T18:54:06+00:00
Remove ScopedTypeVariables => TypeAbstractions

This commit implements [amendment 604](https://github.com/ghc-proposals/ghc-proposals/pull/604/)
to [GHC proposal 448](https://github.com/ghc-proposals/ghc-proposals/pull/448)
by removing the implication of language extensions

  ScopedTypeVariables => TypeAbstractions

To limit breakage, we now allow type arguments in constructor patterns
when both ScopedTypeVariables and TypeApplications are enabled, but
we emit a warning notifying the user that this is deprecated behaviour
that will go away starting in GHC 9.12.

Fixes #23776

- - - - -
fadd5b4d by sheaf at 2023-08-28T18:54:06+00:00
.stderr: ScopedTypeVariables =/> TypeAbstractions

This commit accepts testsuite changes for the changes in the previous
commit, which mean that TypeAbstractions is no longer implied by
ScopedTypeVariables.

- - - - -
4f5fb500 by Greg Steuck at 2023-08-29T07:55:13-04:00
Repair `codes` test on OpenBSD by explicitly requesting extended RE

- - - - -
6bbde581 by Vasily Sterekhov at 2023-08-29T12:06:58-04:00
Add test for #23540

`T23540.hs` makes use of `explainEv` from `HieQueries.hs`, so
`explainEv` has been moved to `TestUtils.hs`.

- - - - -
257bb3bd by Vasily Sterekhov at 2023-08-29T12:06:58-04:00
Add test for #23120

- - - - -
4f192947 by Vasily Sterekhov at 2023-08-29T12:06:58-04:00
Make some evidence uses reachable by toHie

Resolves #23540, #23120

This adds spans to certain expressions in the typechecker and renamer,
and lets 'toHie' make use of those spans. Therefore the relevant
evidence uses for the following syntax will now show up under the
expected nodes in 'HieAst's:

- Overloaded literals ('IsString', 'Num', 'Fractional')

- Natural patterns and N+k patterns ('Eq', 'Ord', and instances from the
  overloaded literals being matched on)

- Arithmetic sequences ('Enum')

- Monadic bind statements ('Monad')

- Monadic body statements ('Monad', 'Alternative')

- ApplicativeDo ('Applicative', 'Functor')

- Overloaded lists ('IsList')

Also see Note [Source locations for implicit function calls]

In the process of handling overloaded lists I added an extra 'SrcSpan'
field to 'VAExpansion' - this allows us to more accurately reconstruct
the locations from the renamer in 'rebuildHsApps'. This also happens to
fix #23120.

See the additions to Note [Looking through HsExpanded]

- - - - -
fe9fcf9d by Sylvain Henry at 2023-08-29T12:07:50-04:00
ghc-heap: rename C file (fix #23898)

- - - - -
b60d6576 by Krzysztof Gogolewski at 2023-08-29T12:08:29-04:00
Misc cleanup

- Builtin.PrimOps: ReturnsAlg was used only for unboxed tuples.
  Rename to ReturnsTuple.
- Builtin.Utils: use SDoc for a panic message.
  The comment about <<details unavailable>> was obsoleted by e8d356773b56.
- TagCheck: fix wrong logic. It was zipping a list 'args' with its
  version 'args_cmm' after filtering.
- Core.Type: remove an outdated 1999 comment about unlifted polymorphic types
- hadrian: remove leftover debugging print

- - - - -
3054fd6d by Krzysztof Gogolewski at 2023-08-29T12:09:08-04:00
Add a regression test for #23903

The bug has been fixed by commit bad2f8b8aa8424.

- - - - -
21584b12 by Ben Gamari at 2023-08-29T19:52:02-04:00
README: Refer to ghc-hq repository for contributor and governance information

- - - - -
e542d590 by sheaf at 2023-08-29T19:52:40-04:00
Export setInertSet from GHC.Tc.Solver.Monad

We used to export getTcSInerts and setTcSInerts from GHC.Tc.Solver.Monad.
These got renamed to getInertSet/setInertSet in e1590ddc. That commit also removed
the export of setInertSet, but that function is useful for the GHC API.

- - - - -
694ec5b1 by sheaf at 2023-08-30T10:18:32-04:00
Don't bundle children for non-parent Avails

We used to bundle all children of the parent Avail with things that
aren't the parent, e.g. with

  class C a where
    type T a
    meth :: ..

we would bundle the whole Avail (C, T, meth) with all of C, T and meth,
instead of only with C.

Avoiding this fixes #23570

- - - - -
d926380d by Krzysztof Gogolewski at 2023-08-30T10:19:08-04:00
Fix typos

- - - - -
d07080d2 by Josh Meredith at 2023-08-30T19:42:32-04:00
JS: Implement missing C functions `rename`, `realpath`, and `getcwd` (#23806)

- - - - -
e2940272 by David Binder at 2023-08-30T19:43:08-04:00
Bump submodules of hpc and hpc-bin to version 0.7.0.0

hpc 0.7.0.0 dropped SafeHaskell safety guarantees in order to simplify
compatibility with newer versions of the directory package which
dropped all SafeHaskell guarantees.

- - - - -
5d56d05c by David Binder at 2023-08-30T19:43:08-04:00
Bump hpc bound in ghc.cabal.in

- - - - -
99fff496 by Dominik Schrempf at 2023-08-31T00:04:46-04:00
ghc classes documentation: rm redundant comment

- - - - -
fe021bab by Dominik Schrempf at 2023-08-31T00:04:46-04:00
prelude documentation: various nits

- - - - -
48c84547 by Dominik Schrempf at 2023-08-31T00:04:46-04:00
integer documentation: minor corrections

- - - - -
20cd12f4 by Dominik Schrempf at 2023-08-31T00:04:46-04:00
real documentation: nits

- - - - -
dd39bdc0 by sheaf at 2023-08-31T00:05:27-04:00
Add a test for #21765

This issue (of reporting a constraint as being redundant even though
removing it causes typechecking to fail) was fixed in aed1974e.
This commit simply adds a regression test.

Fixes #21765

- - - - -
f1ec3628 by Andrew Lelechenko at 2023-08-31T23:53:30-04:00
Export foldl' from Prelude and bump submodules

See https://github.com/haskell/core-libraries-committee/issues/167 for discussion

Metric Decrease:
    T8095
    T13386
Metric Increase:
    T13386
    T8095

T8095 ghc/alloc decreased on x86_64, but increased on aarch64.
T13386 ghc/alloc decreased on x86_64-windows, but increased on other platforms.
Neither has anything to do with `foldl'`, so I conclude that both are flaky.

- - - - -
3181b97d by Gergő Érdi at 2023-08-31T23:54:06-04:00
Allow cross-tyvar defaulting proposals from plugins

Fixes #23832.

- - - - -
e4af506e by Sebastian Graf at 2023-09-01T14:29:12-04:00
Clarify Note [GlobalId/LocalId] after CorePrep (#23797)

Fixes #23797.

- - - - -
ac29787c by Sylvain Henry at 2023-09-01T14:30:02-04:00
Fix warning with UNPACK on sum type (#23921)

- - - - -
9765ac7b by Zubin Duggal at 2023-09-05T00:37:45-04:00
hadrian: track python dependencies in doc rules

- - - - -
1578215f by sheaf at 2023-09-05T00:38:26-04:00
Bump Haddock to fix #23616

This commit updates the Haddock submodule to include
the fix to #23616.

Fixes #23616

- - - - -
5a2fe35a by David Binder at 2023-09-05T00:39:07-04:00
Fix example in GHC user guide in SafeHaskell section

The example given in the SafeHaskell section uses an implementation of
Monad which no longer works. This MR removes the non-canonical return
instance and adds the necessary instances of Functor and Applicative.

- - - - -
291d81ae by Matthew Pickering at 2023-09-05T14:03:10-04:00
driver: Check transitive closure of haskell package dependencies when deciding whether to relink

We were previously just checking whether direct package dependencies had
been modified. This caused issues when compiling without optimisations
as we wouldn't relink the direct dependency if one of its dependenices
changed.

Fixes #23724

- - - - -
35da0775 by Krzysztof Gogolewski at 2023-09-05T14:03:47-04:00
Re-export GHC.Utils.Panic.Plain from GHC.Utils.Panic

Fixes #23930

- - - - -
3930d793 by Jaro Reinders at 2023-09-06T18:42:55-04:00
Make STG rewriter produce updatable closures

- - - - -
0104221a by Krzysztof Gogolewski at 2023-09-06T18:43:32-04:00
configure: update message to use hadrian (#22616)

- - - - -
b34f8586 by Alan Zimmerman at 2023-09-07T10:58:38-04:00
EPA: Incorrect locations for UserTyVar with '@'

In T13343.hs, the location for the @ is not within the span of the
surrounding UserTyVar.

  type Bad @v = (forall (v1 :: RuntimeRep) (a1 :: TYPE v). a1) :: TYPE v

Widen it so it is captured.

Closes #23887

- - - - -
8046f020 by Finley McIlwaine at 2023-09-07T10:59:15-04:00
Bump haddock submodule to fix #23920

Removes the fake export of `FUN` from Prelude. Fixes #23920.

Bumps haddock submodule.

- - - - -
e0aa8c6e by Krzysztof Gogolewski at 2023-09-07T11:00:03-04:00
Fix wrong role in mkSelCo_maybe

In the Lint failure in #23938, we start with a coercion Refl :: T a ~R T a,
and call mkSelCo (SelTyCon 1 nominal) Refl.
The function incorrectly returned Refl :: a ~R a. The returned role
should be nominal, according to the SelCo rule:

      co : (T s1..sn) ~r0 (T t1..tn)
      r = tyConRole tc r0 i
      ----------------------------------
      SelCo (SelTyCon i r) : si ~r ti

In this test case, r is nominal while r0 is representational.

- - - - -
1d92f2df by Gergő Érdi at 2023-09-08T04:04:30-04:00
If we have multiple defaulting plugins, then we should zonk in between them

after any defaulting has taken place, to avoid a defaulting plugin seeing
a metavariable that has already been filled.

Fixes #23821.

- - - - -
eaee4d29 by Gergő Érdi at 2023-09-08T04:04:30-04:00
Improvements to the documentation of defaulting plugins

Based on @simonpj's draft and comments in !11117

- - - - -
ede3df27 by Alan Zimmerman at 2023-09-08T04:05:06-04:00
EPA: Incorrect span for LWarnDec GhcPs

The code (from T23465.hs)

    {-# WARNInG in "x-c" e "d" #-}
    e = e

gives an incorrect span for the LWarnDecl GhcPs

Closes #23892

It also fixes the Test23465/Test23464 mixup

- - - - -
a0ccef7a by Krzysztof Gogolewski at 2023-09-08T04:05:42-04:00
Valid hole fits: don't suggest unsafeCoerce (#17940)

- - - - -
88b942c4 by Oleg Grenrus at 2023-09-08T19:58:42-04:00
Add warning for badly staged types.

Resolves #23829.

The stage violation results in out-of-bound names in splices.
Technically this is an error, but someone might rely on this!?

Internal changes:
- we now track stages for TyVars.
- thLevel (RunSplice _) = 0, instead of panic, as reifyInstances does
  in fact rename its argument type, and it can contain variables.

- - - - -
9861f787 by Ben Gamari at 2023-09-08T19:59:19-04:00
rts: Fix invalid symbol type

I suspect this code is dead since we haven't observed this failing
despite the obviously incorrect macro name.

- - - - -
03ed6a9a by Ben Gamari at 2023-09-08T19:59:19-04:00
testsuite: Add simple test exercising C11 atomics in GHCi

See #22012.

- - - - -
1aa5733a by Ben Gamari at 2023-09-08T19:59:19-04:00
rts/RtsSymbols: Add AArch64 outline atomic operations

Fixes #22012 by adding the symbols described in
https://github.com/llvm/llvm-project/blob/main/llvm/docs/Atomics.rst#libcalls-atomic.

Ultimately this would be better addressed by #22011, but this is a first
step in the right direction and fixes the immediate symptom.

Note that we dropped the `__arch64_cas16` operations as these provided
by all platforms's compilers. Also, we don't link directly against the
libgcc/compiler-rt definitions but rather provide our own wrappers to
work around broken toolchains (e.g. https://bugs.gentoo.org/868018).

Generated via https://gitlab.haskell.org/ghc/ghc/-/snippets/5733.

- - - - -
8f7d3041 by Matthew Pickering at 2023-09-08T19:59:55-04:00
ci: Build debian12 and fedora38 bindists

This adds builds for the latest releases for fedora and debian

We build these bindists in nightly and release pipelines.

- - - - -
a1f0d55c by Felix Leitz at 2023-09-08T20:00:37-04:00
Fix documentation around extension implication for MultiParamTypeClasses/ConstrainedClassMethods.

- - - - -
98166389 by Teo Camarasu at 2023-09-12T04:30:54-04:00
docs: move -xn flag beside --nonmoving-gc

It makes sense to have these beside each other as they are aliases.

- - - - -
f367835c by Teo Camarasu at 2023-09-12T04:30:55-04:00
nonmoving: introduce a family of dense allocators

Supplement the existing power 2 sized nonmoving allocators with a family
of dense allocators up to a configurable threshold.

This should reduce waste from rounding up block sizes while keeping the
amount of allocator sizes manageable.

This patch:
  - Adds a new configuration option `--nonmoving-dense-allocator-count`
    to control the amount of these new dense allocators.
  - Adds some constants to `NonmovingAllocator` in order to keep
    marking fast with the new allocators.

Resolves #23340

- - - - -
2b07bf2e by Teo Camarasu at 2023-09-12T04:30:55-04:00
Add changelog entry for #23340

- - - - -
f96fe681 by sheaf at 2023-09-12T04:31:44-04:00
Use printGhciException in run{Stmt, Decls}

When evaluating statements in GHCi, we need to use printGhciException
instead of the printException function that GHC provides in order to
get the appropriate error messages that are customised for ghci use.

- - - - -
d09b932b by psilospore at 2023-09-12T04:31:44-04:00
T23686: Suggest how to enable Language Extension when in ghci
Fixes #23686

- - - - -
da30f0be by Matthew Craven at 2023-09-12T04:32:24-04:00
Unarise: Split Rubbish literals in function args

Fixes #23914.  Also adds a check to STG lint that
these args are properly unary or nullary after unarisation

- - - - -
261b6747 by Matthew Pickering at 2023-09-12T04:33:04-04:00
darwin: Bump MAXOSX_DEPLOYMENT_TARGET to 10.13

This bumps the minumum supported version to 10.13 (High Sierra) which is
6 years old at this point.

Fixes #22938

- - - - -
f418f919 by Mario Blažević at 2023-09-12T04:33:45-04:00
Fix TH pretty-printing of nested GADTs, issue #23937

This commit fixes `Language.Haskell.TH.Ppr.pprint` so that it correctly
pretty-prints GADTs declarations contained within data family instances.

Fixes #23937

- - - - -
d7a64753 by John Ericson at 2023-09-12T04:34:20-04:00
Put hadrian non-bootstrap plans through `jq`

This makes it possible to review changes with conventional diffing
tools.

This is picking up where ad8cfed4195b1bbfc15b841f010e75e71f63157d left
off.

- - - - -
ff0a709a by Sylvain Henry at 2023-09-12T08:46:28-04:00
JS: fix some tests

- Tests using Setup programs need to pass --with-hc-pkg
- Several other fixes

See https://gitlab.haskell.org/ghc/ghc/-/wikis/javascript-backend/bug_triage
for the current status

- - - - -
fc86f0e7 by Krzysztof Gogolewski at 2023-09-12T08:47:04-04:00
Fix in-scope set assertion failure (#23918)

Patch by Simon

- - - - -
21a906c2 by Matthew Pickering at 2023-09-12T17:21:04+02:00
Add -Winconsistent-flags warning

The warning fires when inconsistent command line flags are passed.

For example:

* -dynamic-too and -dynamic
* -dynamic-too on windows
* -O and --interactive
* etc

This is on by default and allows users to control whether the warning is
displayed and whether it should be an error or not.

Fixes #22572

- - - - -
dfc4f426 by Krzysztof Gogolewski at 2023-09-12T20:31:35-04:00
Avoid serializing BCOs with the internal interpreter

Refs #23919

- - - - -
9217950b by Finley McIlwaine at 2023-09-13T08:06:03-04:00
Fix numa auto configure

- - - - -
98e7c1cf by Simon Peyton Jones at 2023-09-13T08:06:40-04:00
Add -fno-cse to T15426 and T18964

This -fno-cse change is to avoid these performance tests depending on
flukey CSE stuff.  Each contains several independent tests, and we don't
want them to interact.

See #23925.

By killing CSE we expect a 400% increase in T15426, and 100% in T18964.

Metric Increase:
    T15426
    T18964

- - - - -
236a134e by Simon Peyton Jones at 2023-09-13T08:06:40-04:00
Tiny refactor

canEtaReduceToArity was only called internally, and always with
two arguments equal to zero.  This patch just specialises the
function, and renames it to cantEtaReduceFun.

No change in behaviour.

- - - - -
56b403c9 by Ben Gamari at 2023-09-13T19:21:36-04:00
spec-constr: Lift argument limit for SPEC-marked functions

When the user adds a SPEC argument to a function, they are informing us
that they expect the function to be specialised. However, previously
this instruction could be preempted by the specialised-argument limit
(sc_max_args). Fix this.

This fixes #14003.

- - - - -
6840012e by Simon Peyton Jones at 2023-09-13T19:22:13-04:00
Fix eta reduction

Issue #23922 showed that GHC was bogusly eta-reducing a join point.
We should never eta-reduce (\x -> j x) to j, if j is a join point.

It is extremly difficult to trigger this bug.  It took me 45 mins of
trying to make a small tests case, here immortalised as T23922a.

- - - - -
e5c00092 by Andreas Klebinger at 2023-09-14T08:57:43-04:00
Profiling: Properly escape characters when using `-pj`.

There are some ways in which unusual characters like quotes or others
can make it into cost centre names. So properly escape these.

Fixes #23924

- - - - -
ec490578 by Ellie Hermaszewska at 2023-09-14T08:58:24-04:00
Use clearer example variable names for bool eliminator

- - - - -
5126a2fe by Sylvain Henry at 2023-09-15T11:18:02-04:00
Add missing int64/word64-to-double/float rules (#23907)

CLC proposal: https://github.com/haskell/core-libraries-committee/issues/203

- - - - -
566ef411 by Mario Blažević at 2023-09-15T11:18:43-04:00
Fix and test TH pretty-printing of type operator role declarations

This commit fixes and tests `Language.Haskell.TH.Ppr.pprint` so that it
correctly pretty-prints `type role` declarations for operator names.

Fixes #23954

- - - - -
8e05c54a by Simon Peyton Jones at 2023-09-16T01:42:33-04:00
Use correct FunTyFlag in adjustJoinPointType

As the Lint error in #23952 showed, the function adjustJoinPointType
was failing to adjust the FunTyFlag when adjusting the type.

I don't think this caused the seg-fault reported in the ticket,
but it is definitely.  This patch fixes it.

It is tricky to come up a small test case; Krzysztof came up with
this one, but it only triggers a failure in GHC 9.6.

- - - - -
778c84b6 by Pierre Le Marre at 2023-09-16T01:43:15-04:00
Update to Unicode 15.1.0

See: https://www.unicode.org/versions/Unicode15.1.0/

- - - - -
f9d79a6c by Alan Zimmerman at 2023-09-18T00:00:14-04:00
EPA: track unicode version for unrestrictedFunTyCon

Closes #23885

Updates haddock submodule

- - - - -
9374f116 by Andrew Lelechenko at 2023-09-18T00:00:54-04:00
Bump parsec submodule to allow text-2.1 and bytestring-0.12

- - - - -
7ca0240e by Ben Gamari at 2023-09-18T15:16:48-04:00
base: Advertise linear time of readFloat

As noted in #23538, `readFloat` has runtime that scales nonlinearly in
the size of its input. Consequently, its use on untrusted input can
be exploited as a denial-of-service vector. Point this out and suggest
use of `read` instead.

See #23538.

- - - - -
f3f58f13 by Simon Peyton Jones at 2023-09-18T15:17:24-04:00
Remove dead code GHC.CoreToStg.Prep.canFloat

This function never fires, so we can delete it: #23965.

- - - - -
ccab5b15 by Ben Gamari at 2023-09-18T15:18:02-04:00
base/changelog: Move fix for #23907 to 9.8.1 section

Since the fix was backported to 9.8.1

- - - - -
51b57d65 by Matthew Pickering at 2023-09-19T08:44:31-04:00
Add aarch64 alpine bindist

This is dynamically linked and makes creating statically linked
executables more straightforward.

Fixes #23482

- - - - -
02c87213 by Matthew Pickering at 2023-09-19T08:44:31-04:00
Add aarch64-deb11 bindist

This adds a debian 11 release job for aarch64.

Fixes #22005

- - - - -
8b61dfd6 by Alexis King at 2023-09-19T08:45:13-04:00
Don’t store the async exception masking state in CATCH frames

- - - - -
86d2971e by doyougnu at 2023-09-19T19:08:19-04:00
compiler,ghci: error codes link to HF error index

closes: #23259

- adds -fprint-error-index-links={auto|always|never} flag

- - - - -
5f826c18 by sheaf at 2023-09-19T19:09:03-04:00
Pass quantified tyvars in tcDefaultAssocDecl

This commit passes the correct set of quantified type variables written
by the user in associated type default declarations for validity
checking. This ensures that validity checking of associated type defaults
mirrors that of standalone type family instances.

Fixes #23768 (see testcase T23734 in subsequent commit)

- - - - -
aba18424 by sheaf at 2023-09-19T19:09:03-04:00
Avoid panic in mkGADTVars

This commit avoids panicking in mkGADTVars when we encounter
a type variable as in #23784 that is bound by a user-written
forall but not actually used.

Fixes #23784

- - - - -
a525a92a by sheaf at 2023-09-19T19:09:03-04:00
Adjust reporting of unused tyvars in data FamInsts

This commit adjusts the validity checking of data family
instances to improve the reporting of unused type variables.

See Note [Out of scope tvs in data family instances] in GHC.Tc.Validity.

The problem was that, in a situation such as

  data family D :: Type
  data instance forall (d :: Type). D = MkD

the RHS passed to 'checkFamPatBinders' would be the TyCon app

  R:D d

which mentions the type variable 'd' quantified in the user-written
forall. Thus, when computing the set of unused type variables in
the RHS of the data family instance, we would find that 'd' is used,
and report a strange error message that would say that 'd' is not
bound on the LHS.

To fix this, we special-case the data-family instance case,
manually extracting all the type variables that appear in the
arguments of all the data constructores of the data family instance.

Fixes #23778

- - - - -
28dd52ee by sheaf at 2023-09-19T19:09:03-04:00
Unused tyvars in FamInst: only report user tyvars

This commit changes how we perform some validity checking for
coercion axioms to mirror how we handle default declarations for
associated type families. This allows us to keep track of whether
type variables in type and data family instances were user-written
or not, in order to only report the user-written ones in
"unused type variable" error messages.

Consider for example:

  {-# LANGUAGE PolyKinds #-}
  type family F
  type instance forall a. F = ()

In this case, we get two quantified type variables,
(k :: Type) and (a :: k); the second being user-written, but the first
is introduced by the typechecker. We should only report 'a' as being
unused, as the user has no idea what 'k' is.

Fixes #23734

- - - - -
1eed645c by sheaf at 2023-09-19T19:09:03-04:00
Validity: refactor treatment of data families

This commit refactors the reporting of unused type variables in type
and data family instances to be more principled. This avoids ad-hoc
logic in the treatment of data family instances.

- - - - -
35bc506b by John Ericson at 2023-09-19T19:09:40-04:00
Remove `ghc-cabal`

It is dead code since the Make build system was removed.

I tried to go over every match of `git grep -i ghc-cabal` to find other
stray bits. Some of those might be workarounds that can be further
removed.

- - - - -
665ca116 by John Paul Adrian Glaubitz at 2023-09-19T19:10:39-04:00
Re-add unregisterised build support for sparc and sparc64

Closes #23959

- - - - -
142f8740 by Matthew Pickering at 2023-09-19T19:11:16-04:00
Bump ci-images to use updated version of Alex

Fixes #23977

- - - - -
fa977034 by John Ericson at 2023-09-21T12:55:25-04:00
Use Cabal 3.10 for Hadrian

We need the newer version for `CABAL_FLAG_*` env vars for #17191.

- - - - -
a5d22cab by John Ericson at 2023-09-21T12:55:25-04:00
hadrian: `need` any `configure` script we will call

When the script is changed, we should reconfigure.

- - - - -
db882b57 by John Ericson at 2023-09-21T12:55:25-04:00
hadrian: Make it easier to debug Cabal configure

Right now, output is squashed. This make per-package configure scripts
extremely hard to maintain, because we get vague "library is missing"
errors when the actually probably is usually completely unrelated except
for also involving the C/C++ toolchain.

(I can always pass `-VVV` to Hadrian locally, but these errors are
subtle and I often cannot reproduce them locally!)

`--disable-option-checking` was added back in
75c6e0684dda585c37b4ac254cd7a13537a59a91 but seems to be a bit overkill;
if other flags are passed that are not recognized behind the two from
Cabal mentioned in the former comment, we *do* want to know about it.

- - - - -
7ed65f5a by John Ericson at 2023-09-21T12:55:25-04:00
hadrian: Increase verbosity of certain cabal commands

This is a hack to get around the cabal function we're calling
*decreasing* the verbosity it passes to another function, which is the
stuff we often actually care about. Sigh.

Keeping this a separate commit so if this makes things too verbose it is
easy to revert.

- - - - -
a4fde569 by John Ericson at 2023-09-21T12:55:25-04:00
rts: Move most external symbols logic to the configure script

This is much more terse because we are programmatically handling the
leading underscore.

`findPtr` however is still handled in the Cabal file because we need a
newer Cabal to pass flags to the configure script automatically.

Co-Authored-By: Ben Gamari <ben at well-typed.com>

- - - - -
56cc85fb by Andrew Lelechenko at 2023-09-21T12:56:21-04:00
Bump Cabal submodule to allow text-2.1 and bytestring-0.12

- - - - -
0cd6148c by Matthew Pickering at 2023-09-21T12:56:21-04:00
hadrian: Generate Distribution/Fields/Lexer.x before creating a source-dist

- - - - -
b10ba6a3 by Andrew Lelechenko at 2023-09-21T12:56:21-04:00
Bump hadrian's index-state to upgrade alex at least to 3.2.7.3

- - - - -
11ecc37b by Luite Stegeman at 2023-09-21T12:57:03-04:00
JS: correct file size and times

Programs produced by the JavaScript backend were returning
incorrect file sizes and modification times, causing cabal
related tests to fail.

This fixes the problem and adds an additional test that verifies
basic file information operations.

fixes #23980

- - - - -
b35fd2cd by Ben Gamari at 2023-09-21T12:57:39-04:00
gitlab-ci: Drop libiserv from upload_ghc_libs

libiserv has been merged into the ghci package.

- - - - -
37ad04e8 by Ben Gamari at 2023-09-21T12:58:15-04:00
testsuite: Fix Windows line endings

- - - - -
5795b365 by Ben Gamari at 2023-09-21T12:58:15-04:00
testsuite: Use makefile_test

- - - - -
15118740 by Ben Gamari at 2023-09-21T12:58:55-04:00
system-cxx-std-lib: Add license and description
- - - - -
0208f1d5 by Ben Gamari at 2023-09-21T12:59:33-04:00
gitlab/issue-templates: Rename bug.md -> default.md

So that it is visible by default.

- - - - -
23cc3f21 by Andrew Lelechenko at 2023-09-21T20:18:11+01:00
Bump submodule text to 2.1

- - - - -
b8e4fe23 by Andrew Lelechenko at 2023-09-22T20:05:05-04:00
Bump submodule unix to 2.8.2.1

- - - - -
54b2016e by John Ericson at 2023-09-23T11:40:41-04:00
Move lib{numa,dw} defines to RTS configure

Clean up the m4 to handle the auto case always and be more consistent.
Also simplify the CPP --- we should always have both headers if we are
using libnuma.

"side effects" (AC_DEFINE, and AC_SUBST) are removed from the macros to
better separate searching from actions taken based on search results.
This might seem overkill now, but will make shuffling logic between
configure scripts easier later.

The macro comments are converted from `dnl` to `#` following the
recomendation in
https://www.gnu.org/software/autoconf/manual/autoconf-2.71/html_node/Macro-Definitions.html

- - - - -
d51b601b by John Ericson at 2023-09-23T11:40:50-04:00
Shuffle libzstd configuring between scripts

Like the prior commit for libdw and libnuma, `AC_DEFINE` to RTS
configure, `AC_SUBST` goes to the top-level configure script, and the
documentation of the m4 macro is improved.

- - - - -
d1425af0 by John Ericson at 2023-09-23T11:41:03-04:00
Move `FP_ARM_OUTLINE_ATOMICS` to RTS configure

It is just `AC_DEFINE` it belongs there instead.

- - - - -
18de37e4 by John Ericson at 2023-09-23T11:41:03-04:00
Move mmap in the runtime linker check to the RTS configure

`AC_DEFINE` should go there instead.

- - - - -
74132c2b by Andrew Lelechenko at 2023-09-25T21:56:54-04:00
Elaborate comment on GHC_NO_UNICODE

- - - - -
de142aa2 by Ben Gamari at 2023-09-26T15:25:03-04:00
gitlab-ci: Mark T22012 as broken on CentOS 7

Due to #23979.

- - - - -
6a896ce8 by Teo Camarasu at 2023-09-26T15:25:39-04:00
hadrian: better error for failing to find file's dependencies

Resolves #24004

- - - - -
d697a6c2 by Stefan Holdermans at 2023-09-26T20:58:37+00:00
Refactor uses of `partitionEithers . map`

This patch changes occurences of the idiom
`partitionEithers (map f xs)` by the simpler form
`partitionWith f xs` where `partitionWith` is the utility function
defined in `GHC.Utils.Misc`.

Resolves: #23953

- - - - -
8a2968b7 by Stefan Holdermans at 2023-09-26T20:58:37+00:00
Refactor uses of `partitionEithers <$> mapM f xs`

This patch changes occurences of the idiom
`partitionEithers <$> mapM f xs` by the simpler form
`partitionWithM f xs` where `partitionWithM` is a utility function
newly added to `GHC.Utils.Misc`.

- - - - -
6a27eb97 by Stefan Holdermans at 2023-09-26T20:58:37+00:00
Mark `GHC.Utils.Misc.partitionWithM` as inlineable

This patch adds an `INLINEABLE` pragma for `partitionWithM` to ensure
that the right-hand side of the definition of this function remains
available for specialisation at call sites.

- - - - -
f1e5245a by David Binder at 2023-09-27T01:19:00-04:00
Add RTS option to supress tix file

- - - - -
1f43124f by David Binder at 2023-09-27T01:19:00-04:00
Add expected output to testsuite in test interface-stability/base-exports

- - - - -
b9d2c354 by David Binder at 2023-09-27T01:19:00-04:00
Expose HpcFlags and getHpcFlags from GHC.RTS.Flags

- - - - -
345675c6 by David Binder at 2023-09-27T01:19:00-04:00
Fix expected output of interface-stability test

- - - - -
146e1c39 by David Binder at 2023-09-27T01:19:00-04:00
Implement getHpcFlags

- - - - -
61ba8e20 by David Binder at 2023-09-27T01:19:00-04:00
Add section in user guide

- - - - -
ea05f890 by David Binder at 2023-09-27T01:19:01-04:00
Rename --emit-tix-file to --write-tix-file

- - - - -
cabce2ce by David Binder at 2023-09-27T01:19:01-04:00
Update the golden files for interface stability

- - - - -
1dbdb9d0 by Krzysztof Gogolewski at 2023-09-27T01:19:37-04:00
Refactor: introduce stgArgRep

The function 'stgArgType' returns the type in STG. But this violates
the abstraction: in STG we're supposed to operate on PrimReps.

This introduces
stgArgRep ty = typePrimRep (stgArgType ty)
stgArgRep1 ty = typePrimRep1 (stgArgType ty)
stgArgRep_maybe ty = typePrimRep_maybe (stgArgType ty)

stgArgType is still directly used for unboxed tuples (should be fixable), FFI
and in ticky.

- - - - -
b02f8042 by Mario Blažević at 2023-09-27T17:33:28-04:00
Fix TH pretty-printer's parenthesization

This PR Fixes `Language.Haskell.TH.Ppr.pprint` so it correctly emits parentheses where needed.

Fixes #23962, #23968, #23971, and #23986

- - - - -
79104334 by Krzysztof Gogolewski at 2023-09-27T17:34:04-04:00
Add a testcase for #17564

The code in the ticket relied on the behaviour of Derived constraints.
Derived constraints were removed in GHC 9.4 and now the code works
as expected.

- - - - -
d7a80143 by sheaf at 2023-09-28T03:25:53-04:00
lint-codes: add new modes of operation

This commit adds two new modes of operation to the lint-codes
utility:

  list - list all statically used diagnostic codes
  outdated - list all outdated diagnostic codes

The previous behaviour is now:

  test - test consistency and coverage of diagnostic codes

- - - - -
477d223c by sheaf at 2023-09-28T03:25:53-04:00
lint codes: avoid using git-grep

We manually traverse through the filesystem to find the diagnostic codes
embedded in .stdout and .stderr files, to avoid any issues with old
versions of grep.

Fixes #23843

- - - - -
a38ae69a by sheaf at 2023-09-28T03:25:53-04:00
lint-codes: add Hadrian targets

This commit adds new Hadrian targets:

  codes, codes:used - list all used diagnostic codes
  codes:outdated - list outdated diagnostic codes

This allows users to easily query GHC for used and outdated
diagnostic codes, e.g.

  hadrian/build -j --flavour=<..> codes

will list all used diagnostic codes in the command line by running
the lint-codes utility in the "list codes" mode of operation.

The diagnostic code consistency and coverage test is still run as usual,
through the testsuite:

  hadrian/build test --only="codes"

- - - - -
9cdd629b by Ben Gamari at 2023-09-28T03:26:29-04:00
hadrian: Install LICENSE files in bindists

Fixes #23548.

- - - - -
b8ebf876 by Matthew Craven at 2023-09-28T03:27:05-04:00
Fix visibility when eta-reducing a type lambda

Fixes #24014.

- - - - -
3788b487 by Vladislav Zavialov at 2023-09-28T21:59:22+03:00
WIP: T2T in Expressions

- - - - -
4c84e8a5 by Vladislav Zavialov at 2023-09-29T00:21:41+03:00
WIP: T2T corner cases

- - - - -
a614d155 by Vladislav Zavialov at 2023-09-29T17:04:02+03:00
WIP: T2T reject punned variables

- - - - -


30 changed files:

- .gitlab-ci.yml
- .gitlab/ci.sh
- .gitlab/generate-ci/gen_ci.hs
- .gitlab/issue_templates/bug.md → .gitlab/issue_templates/default.md
- .gitlab/jobs.yaml
- .gitlab/rel_eng/fetch-gitlab-artifacts/fetch_gitlab.py
- .gitlab/rel_eng/upload.sh
- .gitlab/rel_eng/upload_ghc_libs.py
- README.md
- compiler/GHC.hs
- compiler/GHC/Builtin/PrimOps.hs
- compiler/GHC/Builtin/PrimOps/Casts.hs
- compiler/GHC/Builtin/Types.hs
- compiler/GHC/Builtin/Types/Prim.hs
- compiler/GHC/Builtin/Uniques.hs
- compiler/GHC/Builtin/Utils.hs
- compiler/GHC/ByteCode/Linker.hs
- compiler/GHC/Cmm/CLabel.hs
- compiler/GHC/Cmm/DebugBlock.hs
- compiler/GHC/Cmm/Info.hs
- compiler/GHC/Cmm/Pipeline.hs
- compiler/GHC/CmmToAsm.hs
- compiler/GHC/CmmToAsm/BlockLayout.hs
- compiler/GHC/CmmToAsm/CFG.hs
- compiler/GHC/CmmToAsm/PPC/CodeGen.hs
- compiler/GHC/CmmToAsm/Reg/Graph/TrivColorable.hs
- compiler/GHC/CmmToAsm/X86/CodeGen.hs
- compiler/GHC/CmmToAsm/X86/Instr.hs
- compiler/GHC/CmmToAsm/X86/Regs.hs
- compiler/GHC/CmmToLlvm/Base.hs


The diff was not included because it is too large.


View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/933e01be45e0d310e9686850f0695eb0e238b228...a614d155db639fb4ea38a74c3d34db5eedcd6af2

-- 
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/933e01be45e0d310e9686850f0695eb0e238b228...a614d155db639fb4ea38a74c3d34db5eedcd6af2
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/20230929/e2dea31c/attachment-0001.html>


More information about the ghc-commits mailing list