| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
| |
This makes sure the testsuite keeps working when testdir contains
backward slashes.
|
| |
|
|
|
|
|
|
|
|
| |
This eradicates varSetElems from the codebase. This function
used to introduce nondeterminism.
I've also documented benign nondeterminism in three places.
GHC Trac: #4012
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
We dump it in the interface file, so we need to do it in a
deterministic order. I haven't seen any problems with this
during my testing, but that's probably because it's unused.
Test Plan: ./validate
Reviewers: simonmar, austin, bgamari
Subscribers: thomie
Differential Revision: https://phabricator.haskell.org/D2313
GHC Trac Issues: #4012
|
|
|
|
|
|
| |
Like described in the comment, it's OK here.
GHC Trac: #4012
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
I believe this part of code is a bit unused. That's
probably why it never became a problem in my testing.
I'm changing to deterministic sets here to be safer.
Test Plan: ./validate
Reviewers: simonmar, austin, bgamari
Subscribers: thomie
Differential Revision: https://phabricator.haskell.org/D2312
GHC Trac Issues: #4012
|
|
|
|
|
|
| |
It's only used for producing an error message here
GHC Trac: #4012
|
| |
|
|
|
|
|
|
|
| |
There should be no performance impact of switching to the
deterministic set here.
GHC Trac: #4012
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This lets us remove some normalization and makes it
less brittle for the future.
Test Plan: ./validate
Reviewers: ezyang, austin, bgamari, simonmar
Reviewed By: simonmar
Subscribers: thomie
Differential Revision: https://phabricator.haskell.org/D2311
GHC Trac Issues: #4012
|
|
|
|
|
|
| |
It uses uniqSetToList which is nondeterministic.
GHC Trac: #4012
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
MatchFixity was introduced to facilitate use of API Annotations.
HsMatchContext does the same thing with more detail, but is chased
through all over the place to provide context when processing a Match.
Since we already have MatchFixity in the Match, it may as well provide
the full context.
updates submodule haddock
Test Plan: ./validate
Reviewers: austin, goldfire, bgamari
Subscribers: thomie, mpickering
Differential Revision: https://phabricator.haskell.org/D2271
GHC Trac Issues: #12105
(cherry picked from commit 306ecad591951521ac3f5888ca8be85bf749d271)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This impacts at least the order in which version macros are
generated. It's pretty hard to track what kind of nondeterminism
is benign and this should have no performance impact as the number
of packages should be relatively small.
Test Plan: ./validate
Reviewers: simonmar, austin, bgamari, ezyang
Reviewed By: ezyang
Subscribers: thomie
Differential Revision: https://phabricator.haskell.org/D2308
GHC Trac Issues: #4012
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
I planned to just say that we don't care about this part.
Turns out I was able to document away the uses in the codegenerator.
Test Plan: ./validate
Reviewers: simonmar, austin, bgamari
Subscribers: thomie
Differential Revision: https://phabricator.haskell.org/D2307
GHC Trac Issues: #4012
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary: Like explained in the comment it's OK here.
Test Plan: ./validate
Reviewers: simonmar, austin, bgamari
Subscribers: thomie
Differential Revision: https://phabricator.haskell.org/D2306
GHC Trac Issues: #4012
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
nameSetElems used `eltsUFM` which is nondeterministic.
Test Plan: ./validate
Reviewers: simonmar, austin, bgamari
Subscribers: thomie
Differential Revision: https://phabricator.haskell.org/D2305
GHC Trac Issues: #4012
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This fixes a problem described in
Note [Deterministic ApplicativeDo and RecursiveDo desugaring].
Test Plan: ./validate + new testcase
Reviewers: simonpj, bgamari, austin, simonmar
Reviewed By: simonmar
Subscribers: thomie
Differential Revision: https://phabricator.haskell.org/D2287
GHC Trac Issues: #4012
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Add @since annotations to instances in `base`.
Test Plan:
* ./validate # some commets shouldn't break the build
* review the annotations for absurdities.
Reviewers: ekmett, goldfire, RyanGlScott, austin, hvr, bgamari
Reviewed By: RyanGlScott, hvr, bgamari
Subscribers: thomie
Differential Revision: https://phabricator.haskell.org/D2277
GHC Trac Issues: #11767
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
We need CallInfoSet to be deterministic because it determines the
order that the binds get generated.
Currently it's not deterministic because it's keyed on
`CallKey = [Maybe Type]` and `Ord CallKey` is implemented
with `cmpType` which is nondeterministic.
See Note [CallInfoSet determinism] for more details.
Test Plan: ./validate
Reviewers: simonpj, bgamari, austin, simonmar
Reviewed By: simonmar
Subscribers: thomie
Differential Revision: https://phabricator.haskell.org/D2242
GHC Trac Issues: #4012
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This isn't strictly necessary for deterministic ABIs.
The results of eltsHpt are consumed in two ways:
1) they determine the order of linking
2) if you track the data flow all the family instances get put in
FamInstEnvs, so the nondeterministic order is forgotten.
3) same for VectInfo stuff
4) same for Annotations
The problem is that I haven't found a nice way to do 2. in
a local way and 1. is nice to have if we went for deterministic
object files. Besides these maps are keyed on ModuleNames so they
should be small relative to other things and the overhead should
be negligible.
As a bonus we also get more specific names.
Test Plan: ./validate
Reviewers: bgamari, austin, hvr, ezyang, simonmar
Reviewed By: simonmar
Subscribers: thomie
Differential Revision: https://phabricator.haskell.org/D2300
GHC Trac Issues: #4012
|
|
|
|
| |
Signed-off-by: Edward Z. Yang <ezyang@cs.stanford.edu>
|
|
|
|
| |
Signed-off-by: Edward Z. Yang <ezyang@cs.stanford.edu>
|
|
|
|
|
|
|
| |
Resolve confusion resulting from:
* 6746549772c5cc0ac66c0fce562f297f4d4b80a2 (typo in 64 + 32 bit numbers)
* ae86eb9f72fa7220fe47ac54d6d21395691c1308 (corrects 64 bit number)
* 1a8d61ca1a54820d2bc30c6a964312faf76d0635 (corrects 32 bit number)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
Adding support for the `R_X86_64_REX_GOTPCRELX` relocation type.
This relocation is treated by the linker the same as the `R_X86_64_GOTPCRELX` type
`G + GOT + A - P` to generate relative offsets to the GOT.
The `REX` prefix has no influence in this stage.
This is based on https://github.com/hjl-tools/x86-psABI/wiki/x86-64-psABI-r252.pdf
Test Plan: ./validate
Reviewers: erikd, austin, bgamari, simonmar
Reviewed By: erikd
Subscribers: thomie, #ghc_windows_task_force
Differential Revision: https://phabricator.haskell.org/D2303
GHC Trac Issues: #12147
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
The spiritual successor to D2291, since deriving `Bounded` instances
in `GHC.Enum` wasn't possible prior to changes made in that Diff.
This Diff finds every manually implemented `Bounded` instance in `base` that is
completely equivalent to the derived instances, and replaces it.
Reviewers: bgamari, goldfire, austin, hvr
Reviewed By: austin, hvr
Subscribers: thomie, rwbarton
Differential Revision: https://phabricator.haskell.org/D2301
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Take the pointer notation out of the typedef such that it preserves the
fact that these are pointers at the use site.
Test Plan:
./validate on all platforms that use the runtime linker.
For unix platforms please ensure `DYNAMIC_GHC_PROGRAMS=NO` is
added to your validate file.
Continuation of D2250
Reviewers: austin, bgamari, simonmar, erikd
Reviewed By: erikd
Subscribers: thomie, #ghc_windows_task_force
Differential Revision: https://phabricator.haskell.org/D2302
GHC Trac Issues: #11816
|
|
|
|
|
|
|
|
|
|
|
|
| |
Reviewers: simonmar, duncan, erikd, austin
Reviewed By: austin
Subscribers: thomie
Differential Revision: https://phabricator.haskell.org/D2290
GHC Trac Issues: #12059
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Use C compiler builtins for atomic SMP primitives. This saves a lot
of CPP ifdefs.
Add test for atomic xchg:
Test if __sync_lock_test_and_set() builtin stores the second argument.
The gcc manual says the actual value stored is implementation defined.
Test Plan: validate and eyeball generated assembler code
Reviewers: kgardas, simonmar, hvr, bgamari, austin, erikd
Reviewed By: simonmar
Subscribers: thomie
Differential Revision: https://phabricator.haskell.org/D2233
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Previously the promoted datacons of the boxed tuple types were not
included in knownKeyNames, which lead to #12132.
Test Plan: Test with included TypeOf testcase
Reviewers: austin, simonpj
Reviewed By: simonpj
Subscribers: thomie
Differential Revision: https://phabricator.haskell.org/D2279
GHC Trac Issues: #12132
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Give `minusInteger` its own implementation.
Previously `minusInteger` used `plusInteger` and `negateInteger`, which
meant it always allocated. Now it works more like `plusInteger`.
Reviewers: goldfire, hvr, bgamari, austin
Reviewed By: hvr, bgamari, austin
Subscribers: thomie
Differential Revision: https://phabricator.haskell.org/D2278
GHC Trac Issues: #12129
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Replace `char*` and `void*` with `SymbolName` and `SymbolAddr` in
`Linker.c`. Gives some useful information about what the variables are
used for and also normalizes the types used in Mac, Linux and Windows
Test Plan:
./validate on all platforms that use the runtime linker.
For unix platforms please ensure `DYNAMIC_GHC_PROGRAMS=NO` is
added to your validate file.
This is a continuation from D2184
Reviewers: austin, erikd, simonmar, bgamari
Reviewed By: bgamari
Subscribers: thomie, #ghc_windows_task_force
Differential Revision: https://phabricator.haskell.org/D2250
GHC Trac Issues: #11816
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Previously as part of #11223 a new struct `SymbolInfo` was introduced to
keep track it the weak symbol status of a symbol.
This structure also kept a copy of the calculated address of the symbol
which turns out was useful in ignoring non-weak zero-valued symbols.
The information was kept in an array so it means for every symbol two
extra bytes were kept even though the vast majority of symbols are
non-weak and non-zero valued.
This changes the array into a sparse map keeping this information only
for the symbols that are weak or zero-valued. This allows for a
reduction in the amount of information needed to be kept while giving up
a small (negligable) hit in performance as this information now has to
be looked up in hashmaps.
Test Plan: ./validate on all platforms that use the runtime linker.
For unix platforms please ensure `DYNAMIC_GHC_PROGRAMS=NO` is added to
your validate file.
Reviewers: simonmar, austin, erikd, bgamari
Reviewed By: simonmar, bgamari
Subscribers: thomie, #ghc_windows_task_force
Differential Revision: https://phabricator.haskell.org/D2184
GHC Trac Issues: #11816
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Mark all failing tests that have a ticket for powerpc64 as broken. Most
of these failures are due to the lack of linker support in the runtime
system.
Test Plan: validate on powerpc and AIX
Reviewers: erikd, bgamari, simonmar, hvr, austin
Reviewed By: austin
Subscribers: thomie
Differential Revision: https://phabricator.haskell.org/D2289
GHC Trac Issues: #11261, #11259, #11260, #11323
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
Currently, none of the `Data` instances in `Data.Data` are derived,
which has resulted in hundreds of lines of laboriously hand-written `Data`
instances. This cleans it up by using `DeriveDataTypeable` to derive all of
the boring instances.
Note that previously, `tcTopSrcDecls` in `TcRnDriver` was typechecking the
variables generated in `deriving` statements before other top-level variables,
which causes an error when `DeriveDataTypeable` is used in `Data.Data`, since
the `deriving`-generated variable definitions refer to top-level definitions
in `Data.Data` itself. To fix this, the order in which these two groups are
typechecked was reversed.
Test Plan: ./validate
Reviewers: rwbarton, bgamari, hvr, austin
Reviewed By: austin
Subscribers: rwbarton, thomie
Differential Revision: https://phabricator.haskell.org/D2291
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Like explained in the comment it's OK here.
Test Plan: ./validate
Reviewers: bgamari, austin, simonmar
Reviewed By: simonmar
Subscribers: thomie
Differential Revision: https://phabricator.haskell.org/D2298
GHC Trac Issues: #4012
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This lets us kill fsEnvElts function which is nondeterministic.
We also get better guarantees than just comments.
We don't do lookups, but I believe a set is needed for deduplication.
Test Plan: ./validate
Reviewers: bgamari, mpickering, austin, simonmar
Reviewed By: simonmar
Subscribers: thomie
Differential Revision: https://phabricator.haskell.org/D2297
GHC Trac Issues: #4012
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This change isn't necessary for determinism. appAName, choiceAName,
loopAName all have pre-allocated Uniques and their relative order
can't change. I opted to use nameSetElemsStable here because:
* the cost is negligible
* it's less fragile than just documenting
Test Plan: ./validate
Reviewers: simonpj, austin, bgamari, simonmar
Reviewed By: simonmar
Subscribers: thomie
Differential Revision: https://phabricator.haskell.org/D2292
GHC Trac Issues: #4012
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
nameSetElems is nondeterministic and while I think we don't need
determinism here it doesn't hurt.
Test Plan: ./validate
Reviewers: ezyang, bgamari, austin, simonmar
Reviewed By: simonmar
Subscribers: thomie
Differential Revision: https://phabricator.haskell.org/D2293
GHC Trac Issues: #4012
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This is not necessary for determinism, but it's a choice
between making this deterministic and using `nonDetEltsUFM`
and a comment explaining that it doesn't matter.
Test Plan: ./validate
Reviewers: austin, hvr, bgamari, simonmar
Reviewed By: simonmar
Subscribers: thomie
Differential Revision: https://phabricator.haskell.org/D2295
GHC Trac Issues: #4012
|
|
|
|
|
|
|
|
| |
Before #9766 was fixed, GHC would generate auxiliary datatypes for every
Generic instance, and it would use functions from OccName to prefix the
generated names. GHC no longer generates any auxiliary datatypes for
Generic instances, but the accompanying code was never removed from
OccName (until now).
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
nameSetElems can introduce nondeterminism and while I haven't
observed this being a problem in practice (possibly because this
is dead code) there's no downside to doing this.
Test Plan: ./validate
Reviewers: bgamari, austin, simonpj, simonmar
Reviewed By: simonmar
Subscribers: thomie
Differential Revision: https://phabricator.haskell.org/D2296
GHC Trac Issues: #4012
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
chooseOrphanAnchor now takes a NameSet, relieving the callers
from the burden of converting it to a list
Test Plan: ./validate
Reviewers: bgamari, ezyang, austin, simonmar, simonpj
Subscribers: thomie
Differential Revision: https://phabricator.haskell.org/D2294
GHC Trac Issues: #4012
|
| |
|
|
|
|
|
|
|
| |
This fixes a bug of not being able to create files or directories in
/tmp/ghctest if it was created by a different user.
Trac ticket #11980.
|
|
|
|
| |
nameSetAll is more precise here
|
|
|
|
|
|
|
|
|
|
|
|
| |
Test Plan: validate
Reviewers: simonpj, austin, bgamari
Reviewed By: bgamari
Subscribers: thomie
Differential Revision: https://phabricator.haskell.org/D2207
|