summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* base: Reintroduce fusion for scanrTDecki2019-08-222-1/+46
| | | | While avoiding #16943.
* Add documentation for Hadrian expressionsJames Foster2019-08-222-0/+334
| | | | | This commit adds documentation on Hadrian's 'Expr' type and references the documentation in hadrian/README.md
* Doc: add Haddocks for quotRemWord2 primopSylvain Henry2019-08-221-2/+2
|
* gitlab-ci: Add Windows full build during the nightly pipelineBen Gamari2019-08-221-0/+13
|
* gitlab-ci: Update bootstrap compiled used for Darwin buildsBen Gamari2019-08-191-2/+2
|
* Remove Bag fold specialisations (#16969)Richard Lupton2019-08-1922-75/+50
|
* Use Foldable instance of Bag for specialised Bag folds (#16969)Richard Lupton2019-08-191-19/+26
|
* Re-export foldlM and foldrM from Data.Foldable in MonadUtils (#16969)Richard Lupton2019-08-191-9/+1
|
* Generalized MonadUtils folds to Foldable (#16969)Richard Lupton2019-08-191-6/+5
|
* Fix COMPACT_NFDATA closure size, more CNF sanity checkingÖmer Sinan Ağacan2019-08-182-20/+30
| | | | | | We now do a shallow closure check on objects in compact regions. See the new comment on why we can't do a "normal" closure check.
* expose ModuleInfo.minf_rdr_env for tooling authorsSam Halliday2019-08-181-0/+4
|
* Fix #17067 by making data family type constructors actually injectiveRyan Scott2019-08-183-2/+15
| | | | | | | | `TcTyClsDecls.tcFamDecl1` was using `NotInjective` when creating data family type constructors, which is just plain wrong. This tweaks it to use `Injective` instead. Fixes #17067.
* Typo fix in CoreToStgÖmer Sinan Ağacan2019-08-181-5/+5
|
* Faster exactLog2Sylvain Henry2019-08-181-14/+8
| | | | | | Make `exactLog2` faster (use `countLeadingZeros` and Int32 bit-ops). On my Core i7-9700k Criterion reports ~50% speedup (from 16 to 8ns).
* Document types of LitNumbers, minor refactoring in Literal.hsÖmer Sinan Ağacan2019-08-151-10/+28
|
* Cmm: constant folding `quotRem x 2^N`Sylvain Henry2019-08-151-11/+39
| | | | | | `quot` and `rem` are implemented efficiently when the second argument is a constant power of 2. This patch uses the same implementations for `quotRem` primop.
* Make add_info attach unfoldings (#16615)Tobias Dammers2019-08-156-40/+121
|
* Add test cases for #16615Tobias Dammers2019-08-154-0/+43
|
* Remove unused imports of the form 'import foo ()' (Fixes #17065)James Foster2019-08-1535-40/+14
| | | | | | | | | | | These kinds of imports are necessary in some cases such as importing instances of typeclasses or intentionally creating dependencies in the build system, but '-Wunused-imports' can't detect when they are no longer needed. This commit removes the unused ones currently in the code base (not including test files or submodules), with the hope that doing so may increase parallelism in the build system by removing unnecessary dependencies.
* GHCi supports not-necessarily-lifted join pointsRichard Eisenberg2019-08-1410-36/+130
| | | | | | | | | | | | | | | | Fixes #16509. See Note [Not-necessarily-lifted join points] in ByteCodeGen, which tells the full story. This commit also adds some comments and cleans some code in the byte-code generator, as I was exploring around trying to understand it. (This commit removes an old test -- this is really a GHCi problem, not a pattern-synonym problem.) test case: ghci/scripts/T16509
* Use os.devnull instead of '/dev/null' in the testsuite driver.Andreas Klebinger2019-08-141-4/+26
| | | | | | | | | | | | The later caused issues on windows by being translated into "\\dev\\null" and python then trying to open this non-existant file. So we now use os.devnull inside python and convert it to "/dev/null" when calling out to the shell, which is bound to run in a unix like environment. This fixes an issue a test producing unexpected stderr output failed with a framework failure instead of showing a diff of the output.
* Rework the Binary Integer instance.Andreas Klebinger2019-08-141-22/+74
| | | | | | | | | | | | We used to serialise large integers as strings. Now they are serialized as a list of Bytes. This changes the size for a Integer in the higher 64bit range from 77 to 9 bytes when written to disk. The impact on the general case is small (<1% for interface files) as we don't use many Integers. But for code that uses many this should be a nice benefit.
* Fix binary distributionTamar Christina2019-08-131-1/+0
|
* Add Foldable, Traversable instances for Uniq(D)FMSebastian Graf2019-08-132-4/+38
| | | | | The `UniqDFM` is deterministic, of course, while we provide an unsafe `NonDetUniqFM` wrapper for `UniqFM` to opt into nondeterministic instances.
* Reformat comments in StgSynÖmer Sinan Ağacan2019-08-101-158/+141
| | | | | | | This does not make any changes in the contents -- formatting only. Previously the comments were too noisy and I've always found it very hard to read. Hopefully it's easier to read now.
* Add test for #16893Ömer Sinan Ağacan2019-08-103-0/+93
|
* Add timing on loadInterfaceBen Gamari2019-08-101-1/+2
| | | | | AndreasK recently mentioned that he thought that interface file loading may be a non-trivial cost. Let's measure.
* Consolidate `TablesNextToCode` and `GhcUnreigsterised` in configure (#15548)Joachim Breitner2019-08-1013-43/+78
| | | | | | | | | | | | | | | | | | | | `TablesNextToCode` is now a substituted by configure, where it has the correct defaults and error handling. Nowhere else needs to duplicate that, though we may want the compiler to to guard against bogus settings files. I renamed it from `GhcEnableTablesNextToCode` to `TablesNextToCode` to: - Help me guard against any unfixed usages - Remove any lingering connotation that this flag needs to be combined with `GhcUnreigsterised`. Original reviewers: Original subscribers: TerrorJack, rwbarton, carter Original Differential Revision: https://phabricator.haskell.org/D5082
* Revert "Make scanr a good producer and consumer"Ben Gamari2019-08-072-18/+2
| | | | | | This reverts commit 4e1dfc3767167dddd0e151a2df8305b12aa0f49c. Due to #16943.
* testsuite: Add tests for #16943Ben Gamari2019-08-075-0/+23
|
* Fix bug preventing information about patterns from being serialized in .hie ↵Zubin Duggal2019-08-0711-18/+159
| | | | files
* Fix testmniip2019-08-071-1/+1
|
* Fix documentationmniip2019-08-071-2/+2
|
* Explicitly number equations when printing axiom incompatibilitiesmniip2019-08-073-26/+32
|
* Fix testmniip2019-08-071-9/+7
|
* Add a -fprint-axiom-incomps option (#15546)mniip2019-08-078-25/+103
| | | | | | | | | | | | | | | | | | | | | | | | | | Supply branch incomps when building an IfaceClosedSynFamilyTyCon `pprTyThing` now has access to incomps. This also causes them to be written out to .hi files, but that doesn't pose an issue other than a more faithful bijection between `tyThingToIfaceDecl` and `tcIfaceDecl`. The machinery for displaying axiom incomps was already present but not in use. Since this is now a thing that pops up in ghci's :info the format was modified to look like a haskell comment. Documentation and a test for the new feature included. Test Plan: T15546 Reviewers: simonpj, bgamari, goldfire Reviewed By: simonpj Subscribers: rwbarton, carter GHC Trac Issues: #15546 Differential Revision: https://phabricator.haskell.org/D5097
* Introduce a type for "platform word size", use it instead of IntÖmer Sinan Ağacan2019-08-0611-60/+86
| | | | | | | | We introduce a PlatformWordSize type and use it in platformWordSize field. This removes to panic/error calls called when platform word size is not 32 or 64. We now check for this when reading the platform config.
* Remove old/broken(?) .ghci scriptMatthew Pickering2019-08-061-11/+0
| | | | | | | | | I was attempting to load hadrian into ghci by using `cabal new-repl exe:hadrian` but it failed because it tried to use this `.ghci` configuration. I'm not sure who used this script but you should really use the new-repl method.
* hadrian: Refactor file patterns for future Shake changes (fixes #17005)James Foster2019-08-0616-120/+120
| | | | | | | | | | | | | | | | | Shake will be moving from its current implementation of ?== to one from System.FilePattern. Support for `//` is being dropped, leaving only `*` and `**` as special forms. This commit converts the existing file patterns in Hadrian to the new format. It also removes all occurances of <//> and changes the user-settings docs to remove references to // and add **. The conversion is as follows: - //a ==> **/a - a// ==> a/** - a//b ==> a/**/b
* Remove dead parameter from coreToStgAppSimon Peyton Jones2019-08-061-15/+8
|
* testsuite: Rework tracking of fragile testsBen Gamari2019-08-043-7/+18
| | | | | Breaks fragile tests into two groups, allowing us to easily preserve stdout/stderr of failing fragile tests.
* configure: Search for LLVM executables with two-number versionsBen Gamari2019-08-041-2/+3
| | | | | | | Fedora uses the naming llc-7.0 while Debian uses llc-7. Ensure that both are found. Fixes #16990.
* testsuite: Add testsuite for #16978Ben Gamari2019-08-042-0/+30
|
* Don't float unlifted join points to top levelSimon Peyton Jones2019-08-041-2/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Ticket #16978 showed that we were floating a recursive, unlifted join point to top level. It's very much a corner case: joinrec j :: Int# j = jump j in ... But somehow it showed up in a real program. For non-recursive bindings in SetLevels.lvlBind we were already (correctly) checking for unlifted bindings, but when I wrote that code I didn't think that a /recursive/ binding could be unlifted but /join-points/ can be! Actually I don't think that SetLevels should be floating join points at all. SetLevels really floats things to move stuff out of loops and save allocation; but none of that applies to join points. The only reason to float join points is in cases like join j1 x = join j2 y = ... in ... which we might want to swizzle to join j2 x y = ... in join j1 x = ... in ... because now j1 looks small and might be inlined away altogether. But this is a very local float perhaps better done in the simplifier. Still: this patch fixes the crash, and does so in a way that is harmless if/when we change our strategy for floating join points.
* Update .gitignoreMatthew Pickering2019-08-041-1/+11
| | | | Add some files generated by hadrian and some tooling files
* gitlab-ci: Manually set SPHINXBUILD on WindowsBen Gamari2019-08-041-0/+1
| | | | | | | For some reason configure seems unable to find it on its own. Let's try giving it a hint. Addresses #16398.
* Hadrian: make settings, platformConstants, etc dependencies of lib:ghcAlp Mestanogullari2019-08-024-18/+19
| | | | | | | | | | | This fixes #17003, where a user directly asked for the 'docs-haddock' target without building a complete stage 2 GHC first. Since haddock only depends on lib:ghc, the stage 2 GHC executable wasn't built, and neither were the settings, platformConstants, llvm-passes and llvm-targets files, since they are declared to be dependencies of exe:ghc. This makes sense in general since all GHC API users (haddock is one) will likely want those files to be there.
* Packages: Add timing for package database initializationBen Gamari2019-08-021-2/+7
|
* rts: Always truncate output filesBen Gamari2019-08-025-6/+6
| | | | | | | | | Previously there were numerous places in the RTS where we would fopen with the "w" flag string. This is wrong as it will not truncate the file. Consequently if we write less data than the previous length of the file we will leave garbage at its end. Fixes #16993.
* Add Note [withTiming] in compiler/main/ErrUtils.hsAlp Mestanogullari2019-08-021-0/+95
|