| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
| |
Triggered by an observation by Joachim, Simon felt the urge to clean up
the CSE code a bit. This is the result.
(Code by Simon, commit message and other leg-work by Joachim)
Differential Revision: https://phabricator.haskell.org/D2074
|
|
|
|
|
|
|
| |
This reverts commit 28fe0eea4d161b707f67aae26fddaa2e60d8a901 due to
various regressions. I’m not sure why my local
./validate --slow
run did not catch this, though.
|
|
|
|
|
|
|
|
| |
Richard accidetally introduced this change in his big kind-equality
patch. The code is wrong, and potentially could cause binders to
be re-ordered.
Worth merging to 8.0.
|
|
|
|
|
|
|
|
|
| |
as suggested in ticket:11770#comment:1. This code was buggy (#11770),
and the occurrence analyzer does the same job anyways.
This also elaborates the notes in the occurrence analyzer accordingly.
Differential Revision: https://phabricator.haskell.org/D2070
|
|
|
|
|
|
| |
The result of a series of patches on type-error messages for
pattern synonyms had become a bit baroque. This tidies it up
a bit. Still not fantastic, but better.
|
|
|
|
|
|
|
|
|
| |
For some reason a SigSkol had an ExpType in it, and there were
lots of places where we needed it to have a TcType. And was indeed
always a Check. All a lot of fuss about nothing.
Delete code, fewer failure points, types are more precise.
All good.
|
|
|
|
|
| |
Mainly to make it clearer that tauifyExpType
is a no-op on (Check ty)
|
|
|
|
|
|
|
|
|
|
| |
* Move the several calls of tauifyMultipleMatches into tcMatches,
so that it can be called only once, and the invariants are
clearer
* I discovered in doing this that HsLamCase had a redundant and
tiresome argument, so I removed it. That in turn allowed some
modest but nice code simplification
|
| |
|
|
|
|
| |
No change in behaviour
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This turns `Any` into a standard wired-in type family defined in
`GHC.Types`, instead its current incarnation as a magical creature
provided by the `GHC.Prim`. Also kill `AnyK`.
See #10886.
Test Plan: Validate
Reviewers: simonpj, goldfire, austin, hvr
Reviewed By: simonpj
Subscribers: goldfire, thomie
Differential Revision: https://phabricator.haskell.org/D2049
GHC Trac Issues: #10886
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Test Plan: validate
Reviewers: thomie, austin, bgamari
Reviewed By: bgamari
Subscribers: hvr
Differential Revision: https://phabricator.haskell.org/D2058
GHC Trac Issues: #11763
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Define MIN_VERSION_pkgname and VERSION_pkgname macros for all exposed
packages, without requiring -hide-all-packages.
See #10970 comment 7-10 for discussion.
Reviewers: duncan, ezyang, bgamari, austin
Reviewed By: ezyang
Subscribers: hvr, rwbarton
Differential Revision: https://phabricator.haskell.org/D1869
GHC Trac Issues: #10970
|
|
|
|
|
| |
To clarify what the "pure unifier" does, compared to the
"impure unifiers" in the type checker.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
As pointed out by @simonpj on D2044 we don't need
to compute the free vars of the range of the substitution
as most of them are already carried by the monad.
This should be a tiny performance improvement over the version
from before D2044.
Also removes an extra function that is now unnecessary.
Test Plan: ./validate && ./validate --slow
Reviewers: goldfire, simonpj, austin, bgamari
Reviewed By: simonpj
Subscribers: thomie, simonmar, simonpj
Differential Revision: https://phabricator.haskell.org/D2060
GHC Trac Issues: #11371
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This should require -XScopedTypeVariables. It seems this was previously
handled by RnTypes.rnHsBndrSig which called RnTypes.badKindSigErr but
this was broken in Simon's refactor of wildcards,
1e041b7382b6aa329e4ad9625439f811e0f27232. Here we re-introduce a check
in RnPat. See #11663.
Test Plan: Validate with `T11663`
Reviewers: austin, simonpj
Reviewed By: austin
Subscribers: thomie
Differential Revision: https://phabricator.haskell.org/D2054
GHC Trac Issues: #11663
|
|
|
|
| |
too verbose, and usualy preceded by Str= anyways.
|
|
|
|
|
| |
to be consistent with the other uses of nop vs. top in Demand.hs. Also,
stop prettyprinting top strictness signatures in Core dumps.
|
|
|
|
| |
This is a result of the discussion in ticket:11731#comment:9.
|
| |
|
|
|
|
|
| |
(likely introduced by 99d4e5b4a0bd32813ff8c74e91d2dcf6b3555176, possibly
due to a merge mistake).
|
|
|
|
|
|
|
|
|
|
| |
The report now distinguishes thunks (in the variants single-entry and
standard thunks), constructors and functions (possibly single-entry).
Forthermore, for standard thunks (AP and selector), do not count an
entry when they are allocated. It is not possible to count their
entries, as their code is shared, but better count nothing than count
the wrong thing.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
We need the free vars of `t2` to satisfy the substitution
invariant. Luckily they are in the in-scope carried around.
Test Plan: ./validate
Reviewers: bgamari, austin, goldfire, simonpj
Reviewed By: simonpj
Subscribers: thomie, simonmar
Differential Revision: https://phabricator.haskell.org/D2044
GHC Trac Issues: #11371
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
We will use `ty` in the range of the substitution, hence
the substitution needs `ty`'s free vars in-scope.
They don't seem easily available by other means, so we
just compute them.
Test Plan: ./validate
Reviewers: austin, goldfire, bgamari, simonpj
Reviewed By: simonpj
Subscribers: thomie, simonmar
Differential Revision: https://phabricator.haskell.org/D2043
GHC Trac Issues: #11371
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
`ty` doesn't have to be a closed type, so we need to add its
free vars to the in-scope set. They don't seem to be
available anywhere nearby, so we have to compute them.
Test Plan: ./validate
Reviewers: goldfire, austin, bgamari, simonpj
Reviewed By: simonpj
Subscribers: thomie, simonmar
Differential Revision: https://phabricator.haskell.org/D2042
GHC Trac Issues: #11371
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
DEC OSF/1 (aka Tru64 UNIX) has been discontinued a few years ago already[1].
This removes the undoubtedly bitrotten support for `OSOsf3 :: OS` from GHC's
code-base.
Support for `ArchAlpha :: Arch` may be removed at some later point, as there
may still be users out there running a more or less recent Linux/alpha
distribution on their more-than-a-decade old Alpha hardware...
[1]: https://en.wikipedia.org/wiki/Tru64_UNIX
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Long time ago, IRIX was way ahead of its time in the last century with
its SMP capabilities of scaling up to 1024 processors and other features
such as XFS or OpenGL that originated in IRIX and live on to this day in
other operating systems.
However, IRIX's last software update was in 2006 and support ended
around 2013 according to [1], so it's considered an extinct platform by
now. So this commit message is effectively an obituary for GHC's IRIX
support.
R.I.P. IRIX
[1]: https://en.wikipedia.org/wiki/IRIX
|
|
|
|
|
|
|
| |
The implementation in df26b95559fd467abc0a3a4151127c95cb5011b9
wrongly assumed that all C-ABI subroutine calls would use a
'ForeignLabel' but it turns out that calls inserted via
'emitRtsCall' use 'CmmLabel's instead.
|
| |
|
|
|
|
|
|
|
| |
I had just missed this case when adding my test.
This is relevant to ticket #11473.
Also adds lots of comments.
|
|
|
|
|
|
| |
This was just plain wrong previously.
Test case: typecheck/should_compile/T11754
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This works in conjunction with D2036 to allow useful debug output before
DynFlags has been initializated.
See #11755.
Reviewers: austin
Reviewed By: austin
Subscribers: thomie, gridaphobe
Differential Revision: https://phabricator.haskell.org/D2037
GHC Trac Issues: #11755
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Previously unsafeGlobalDynFlags would bottom if used prior to
initialization. This meant that any attempt to use the pretty-printer
early in the initialization process of the compiler would fail. This is
quite inconvenient.
Here we initialize unsafeGlobalDynFlags with defaultDynFlags, bottoming
only if settings is accessed.
See #11755.
Test Plan: Validate
Reviewers: austin
Reviewed By: austin
Subscribers: thomie, gridaphobe
Differential Revision: https://phabricator.haskell.org/D2036
GHC Trac Issues: #11755
|
|
|
|
|
|
|
|
| |
I had a conversation with Richard about TyBinders
and VisibilityFlags. This patch adds a lot of comments
to explain what is going on. I feel much more secure now.
Richard please check.
|
|
|
|
| |
There's no functional change here, just tidying up
|
|
|
|
|
|
|
|
| |
The function tryEtaReducePrep was being over-ambitious.
When Breakpoint ticks were involved (i.e. in GHCi), eta
reduction left an out-of-scope variable in the Tick.
Easily fixed. Fixes the original report in Trac #111728.
|
| |
|
|
|
|
|
|
| |
Reviewed By: bgamari, trommler
Differential Revision: https://phabricator.haskell.org/D2020
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This extends the previous work to revive the unregisterised GHC build
for AIX/ppc32. Strictly speaking, AIX runs on POWER4 (and later)
hardware, but the PPC32 instructions implemented in the PPC NCG
represent a compatible subset of the POWER4 ISA.
IBM AIX follows the PowerOpen ABI (and shares many similiarites with the
Linux PPC64 ELF V1 NCG backend) but uses the rather limited XCOFF
format (compared to ELF).
This doesn't support dynamic libraries yet.
A major limiting factor is that the AIX assembler does not support the
`@ha`/`@l` relocation types nor the ha16()/lo16() functions Darwin's
assembler supports. Therefore we need to avoid emitting those. In case
of numeric literals we simply compute the functions ourselves, while for
labels we have to use local TOCs and hope everything fits into a 16bit
offset (for ppc32 this gives us at most 16384 entries per TOC section,
which is enough to compile GHC).
Another issue is that XCOFF doesn't seem to have a relocation type for
label-differences, and therefore the label-differences placed into
tables-next-to-code can't be relocated, but the linker may rearrange
different sections, so we need to place all read-only sections into the
same `.text[PR]` section to workaround this.
Finally, the PowerOpen ABI distinguishes between function-descriptors
and actualy entry-point addresses. For AIX we need to be specific when
emitting assembler code whether we want the address of the function
descriptor `printf`) or for the entry-point (`.printf`). So we let the
asm pretty-printer prefix a dot to all emitted subroutine
calls (i.e. `BL`) on AIX only. For now, STG routines' entry-point labels
are not prefixed by a label and don't have any associated
function-descriptor.
Reviewers: austin, trommler, erikd, bgamari
Reviewed By: trommler, erikd, bgamari
Differential Revision: https://phabricator.haskell.org/D2019
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary: Remove `.hi` and `.o` files if the flags `no-keep-hi-files` and
`no-keep-o-files` are given.
Test Plan: ./validate
Reviewers: austin, thomie, bgamari
Reviewed By: thomie, bgamari
Subscribers: thomie
Differential Revision: https://phabricator.haskell.org/D2021
GHC Trac Issues: #4114
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* Comments to explain that a CoVar, whose IdInfo is CoVarId,
is always unlifted (but may be nominal or representational role)
And TyCoRep.isCoercionType picks out only those unlifted
types, NOT the lifted versions
* Introduce Var.NcId for non-co-var Ids
with predicate isNonCoVarId
* Add assertions in CoreSubst that the Id env is only
used for NcIds
* Fix lurking bug in CSE which extended the
CoreSubst Id env with a CoVar
* Fix two bugs in Specialise.spec_call, which wrongly treated
CoVars like NcIds
- needed a varToCoreExpr in one place
- needed extendSubst not extendIdSubst in another
This was the root cause of Trac #11644
Minor refactoring
* Eliminate unused mkDerivedLocalCoVarM, mkUserLocalCoVar
* Small refactor in mkSysLocalOrCoVar
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
Addresses #11549 by defaulting `RuntimeRep` variables to `PtrRepLifted`
and adding a new compiler flag `-fprint-explicit-runtime-reps` to
disable this behavior.
This is just a guess at the right way to go about this. If it's
wrong-beyond-any-hope just say so.
Test Plan: Working on a testcase
Reviewers: goldfire, austin
Subscribers: simonpj, thomie
Differential Revision: https://phabricator.haskell.org/D1961
GHC Trac Issues: #11549
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
As discussed in #2530 we are going to continue to produce parentheses
here in order to preserve compatibility with previous GHC releases. It
was found that dropped parentheses would break some testsuites which
compared against output from Show. This has been documented in the users
guide.
This reverts commit 5692643c9d17e746327588cd6157a923642b7975.
Test Plan: Validate
Reviewers: hvr, austin
Subscribers: thomie
Differential Revision: https://phabricator.haskell.org/D2027
GHC Trac Issues: #2350
|
|
|
|
|
| |
This reverts commit 6c2c853b11fe25c106469da7b105e2be596c17de which was
supposed to be merged as individual commits.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Previously we would try to break explicit lists into a dynamic prefix
and static tail and desugar the former into a `build` expression.
Unfortunately, this heuristic resulted in surprising behavior
(see #11710) and wasn't pulling its weight. Here we drop it (along with
the `-fsimple-list-literals` flag), leaving only the list length
heuristic to determine whether `build` or cons list desugaring should be
used.
Test Plan: Validate
Reviewers: simonpj, austin
Reviewed By: simonpj
Subscribers: thomie
Differential Revision: https://phabricator.haskell.org/D2023
GHC Trac Issues: #11710
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Test Plan: ./validate
Reviewers: austin, bgamari
Reviewed By: bgamari
Subscribers: thomie
Differential Revision: https://phabricator.haskell.org/D2015
GHC Trac Issues: #10320
|