summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* Make generated Ord instances smaller (per #10858).wip/small-ordPetr Prokhorenkov2016-09-015-5/+42
| | | | | | | | | | | | Reviewers: simonpj, bgamari, RyanGlScott, austin Reviewed By: simonpj Subscribers: simonpj, thomie Differential Revision: https://phabricator.haskell.org/D2502 GHC Trac Issues: #10858
* Fix startsVarSym and refactor operator predicates (fixes #4239)Malo Jaffré2016-09-016-32/+26
| | | | | | | | | | | | | | | | | | | startsVarSym used isSymbol which does not recognize valid operators beginning with OtherPunctuation generalCategory (e. g. (·)). Move it to ghc-boot-th for reducing duplication. This patch fixes template-haskell pretty printer, which is used by -ddump-minimal-imports. Reviewers: austin, bgamari Reviewed By: bgamari Subscribers: thomie Differential Revision: https://phabricator.haskell.org/D2480 GHC Trac Issues: #4239
* Revert "Fix startsVarSym and refactor operator predicates (fixes #4239)"Ben Gamari2016-09-016-26/+32
| | | | | This reverts commit 8d35e18d885e60f998a9dddb6db19762fe4c6d92. arc butchered the authorship on this.
* Fix startsVarSym and refactor operator predicates (fixes #4239)Ben Gamari2016-09-016-32/+26
| | | | | | | | | | | | | | | | | | | startsVarSym used isSymbol which does not recognize valid operators beginning with OtherPunctuation generalCategory (e. g. (·)). Move it to ghc-boot-th for reducing duplication. This patch fixes template-haskell pretty printer, which is used by -ddump-minimal-imports. Reviewers: austin, bgamari Reviewed By: bgamari Subscribers: thomie Differential Revision: https://phabricator.haskell.org/D2480 GHC Trac Issues: #4239
* Kill vestiages of DEFAULT_TMPDIRBen Gamari2016-09-013-19/+0
| | | | | | | | | | | | | | | | | It was removed long ago in cf403b50900648063d99afa160d2091a7d6f58c1. Thanks for @rwbarton for catching this. Updates nofib submodule. Test Plan: Validate Reviewers: austin, rwbarton Subscribers: thomie, rwbarton Differential Revision: https://phabricator.haskell.org/D2493 GHC Trac Issues: #12443
* restore -fmax-worker-args handling (Trac #11565)Sergei Trofimovich2016-09-013-5/+37
| | | | | | | | | | | | | | | | | | | | | | | | | | maxWorkerArgs handling was accidentally lost 3 years ago in a major update of demand analysis commit 0831a12ea2fc73c33652eeec1adc79fa19700578 Old regression is noticeable as: - code bloat (requires stack reshuffling) - compilation slowdown (more code to optimise/generate) - and increased heap usage (DynFlags unboxing/reboxing?) On a simple compile benchmark this change causes heap allocation drop from 70G don to 67G (ghc perf build). Signed-off-by: Sergei Trofimovich <siarheit@google.com> Reviewers: simonpj, ezyang, goldfire, austin, bgamari Reviewed By: simonpj, ezyang Subscribers: thomie Differential Revision: https://phabricator.haskell.org/D2503 GHC Trac Issues: #11565
* users_guide: Move initGhcMonad note to 8.0.2 relnotesBen Gamari2016-09-012-5/+12
|
* users_guide: Move -fdefer-out-of-scope-variables note to 8.0.2 relnotesBen Gamari2016-09-012-3/+3
| | | | It will be included in 8.0.2
* users_guide: Move addModFinalizer mention to 8.0.2 release notesBen Gamari2016-09-012-8/+13
|
* users_guide: Document removal of -Wredundant-constraints from -WallBen Gamari2016-09-011-1/+2
|
* Revert "testsuite: Update bytes allocated of parsing001"Ben Gamari2016-09-011-2/+1
| | | | | | | This reverts commit ca6d0eb0f7d28b0245abc2b0783141101e51945f. I'm really not sure what happened with the test build that lead me to believe that this was necessary. Mysterious.
* LoadIFace: Show known names on inconsistent interface fileBen Gamari2016-08-311-1/+6
| | | | | | | | Reviewers: austin Subscribers: simonpj, ezyang, thomie Differential Revision: https://phabricator.haskell.org/D2466
* RnExpr: Fix ApplicativeDo desugaring with RebindableSyntaxBen Gamari2016-08-314-21/+78
| | | | | | | | | | | | | | | | | | | We need to compare against the local return and pure, not returnMName and pureAName. Fixes #12490. Test Plan: Validate, add testcase Reviewers: austin, simonmar Reviewed By: simonmar Subscribers: thomie Differential Revision: https://phabricator.haskell.org/D2499 GHC Trac Issues: #12490
* Remove redundant-constraints from -Wall (#10635)Adam C. Foltzer2016-08-318-9/+33
| | | | | | | | | | | | | | | Removes -Wredundant-constraints from -Wall, as per the discussion in #10635. Reviewers: austin, bgamari Reviewed By: bgamari Subscribers: thomie Differential Revision: https://phabricator.haskell.org/D2498 GHC Trac Issues: #10635
* Add -fdefer-out-of-scope-variables flag (#12170).Eugene Akentyev2016-08-3112-19/+128
| | | | | | | | | | | | Reviewers: simonpj, thomie, austin, bgamari Reviewed By: simonpj, thomie, bgamari Subscribers: simonpj, thomie Differential Revision: https://phabricator.haskell.org/D2458 GHC Trac Issues: #12170
* testsuite: Update bytes allocated of parsing001Ben Gamari2016-08-311-1/+2
| | | | | Sadly I don't know precisely which commit regressed this, but it was quite recent. I'm not sure how this wasn't caught by my test builds.
* PPC NCG: Implement minimal stack frame header.Peter Trommler2016-08-312-8/+27
| | | | | | | | | | | | | | | | | | | | | | | | According to the ABI specifications a minimal stack frame consists of a header and a minimum size parameter save area. We reserve the minimal size for each ABI. On PowerPC 64-bil Linux and AIX the parameter save area can accomodate up to eight parameters. So calls with eight parameters and fewer can be done without allocating a new stack frame and deallocating that stack frame after the call. On AIX one additional spill slot is available on the stack. Code size for all nofib benchmarks is 0.3 % smaller on powerpc64. Test Plan: validate on AIX Reviewers: hvr!, erikd, austin, simonmar, bgamari Reviewed By: bgamari Subscribers: thomie Differential Revision: https://phabricator.haskell.org/D2445
* Add -flocal-ghci-history flag (#9089).Eugene Akentyev2016-08-315-4/+33
| | | | | | | | | | | | Reviewers: thomie, bgamari, austin Reviewed By: thomie, bgamari Subscribers: thomie Differential Revision: https://phabricator.haskell.org/D2461 GHC Trac Issues: #9089
* Add Read1/Read2 methods defined in terms of ReadPrecRyan Scott2016-08-318-62/+397
| | | | | | | | | | | | | | | | | This adds new methods `liftReadList(2)` and `liftReadListPrec(2)` to the `Read1`/`Read2` classes which are defined in terms of `ReadPrec` instead of `ReadS`. This also adds related combinators and changes existing `Read1` and `Read2` instances to be defined in terms of the new methods. Reviewers: hvr, austin, bgamari Reviewed By: bgamari Subscribers: thomie Differential Revision: https://phabricator.haskell.org/D2379 GHC Trac Issues: #12358
* TysWiredIn: Use dataConWorkerUnique instead of incrUniqueBen Gamari2016-08-312-3/+2
| | | | | | | | | | Test Plan: Validate Reviewers: austin Subscribers: thomie Differential Revision: https://phabricator.haskell.org/D2465
* A failing testcase for T12485Bartosz Nitka2016-08-317-0/+39
| | | | | | | | | | | | Test Plan: it's just a testcase Reviewers: ezyang, simonmar, bgamari, austin Subscribers: thomie Differential Revision: https://phabricator.haskell.org/D2450 GHC Trac Issues: #12485
* ErrUtils: Expose accessors of ErrDoc and ErrMsgBen Gamari2016-08-311-4/+7
| | | | | | | | | | | | Test Plan: Validate Reviewers: austin Subscribers: thomie Differential Revision: https://phabricator.haskell.org/D2491 GHC Trac Issues: #12206
* testsuite: Failing testcase for #12091Ben Gamari2016-08-313-0/+6
| | | | | | | | | | | | | | Just as it says on the can Test Plan: validate Reviewers: austin Subscribers: thomie Differential Revision: https://phabricator.haskell.org/D2489 GHC Trac Issues: #12091
* Clarify scope of `getQ`/`putQ` state.Francesco Mazzoli2016-08-311-2/+4
| | | | | | | | | | | | | The current haddocks do not specify the scope of the state manipulated by `getQ`/`putQ`. Reviewers: austin, goldfire, bgamari, ezyang Reviewed By: ezyang Subscribers: ezyang, thomie Differential Revision: https://phabricator.haskell.org/D2497
* StgCmmPrim: Add missing MO_WriteBarrierBen Gamari2016-08-311-2/+5
| | | | | | | | | | | | | | Test Plan: Good question Reviewers: austin, trommler, simonmar, rrnewton Reviewed By: simonmar Subscribers: RyanGlScott, thomie Differential Revision: https://phabricator.haskell.org/D2495 GHC Trac Issues: #12469
* Bump the default allocation area size to 1MBSimon Marlow2016-08-315-8/+11
| | | | | | | | | | | | | | | | | | This is long overdue. Perhaps 1MB is a little on the skinny size, but this is based on * A lot of commodity dual-core desktop processors have 3MB L3 cache * We're traditionally quite frugal with memory by default Test Plan: validate Reviewers: erikd, bgamari, hvr, austin, rwbarton, ezyang Reviewed By: ezyang Subscribers: thomie Differential Revision: https://phabricator.haskell.org/D2496
* iserv: Show usage message on argument parse failureBen Gamari2016-08-312-5/+25
| | | | | | | | | | | | | | Test Plan: validate Reviewers: simonmar, erikd, austin Reviewed By: simonmar, erikd Subscribers: thomie, erikd Differential Revision: https://phabricator.haskell.org/D2494 GHC Trac Issues: #12491
* GHC: Expose installSignalHandlers, withCleanupSessionBen Gamari2016-08-312-3/+9
| | | | | | | | | | | | | | Test Plan: Validate Reviewers: austin, simonmar Reviewed By: simonmar Subscribers: thomie Differential Revision: https://phabricator.haskell.org/D2492 GHC Trac Issues: #12398
* users_guide: More capabilities than processors considered harmfulBen Gamari2016-08-311-1/+2
| | | | | | | | | | | | Test Plan: None. Reviewers: austin, simonmar Reviewed By: simonmar Subscribers: thomie Differential Revision: https://phabricator.haskell.org/D2487
* Fixes #12504: Double-escape paths used to build call to hsc_lineRichard Cook2016-08-316-0/+25
| | | | | | | | | | | | | | | | | | | | | | | | | | In outHsLine, paths passed to construct invocations of hsc_line must be escaped twice in order to generate a properly escaped string literal that will end up in the eventual LINE pragma emitted by this code. This is especially important on Windows paths, where backslashes would otherwise be treated as C escape sequences and result in the incorrect Windows paths. Adds test case to verify that hsc2hs properly escapes file paths in LINE pragmas Updates the hsc2hs submodule. See https://ghc.haskell.org/trac/ghc/ticket/12504 Reviewers: erikd, hvr, austin, bgamari, Phyx Reviewed By: erikd, Phyx Subscribers: thomie, Phyx, mpickering Differential Revision: https://phabricator.haskell.org/D2478 GHC Trac Issues: #12504
* Fix handling of package-db entries in .ghc.environment files, etc.Duncan Coutts2016-08-302-5/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Previously interpreting the content of the .ghc.env files was done after the step that loaded the available package dbs. This meant that setting the package db flags was ineffective. This patch moves interpreting the env files before loading of the package dbs. Also, the package-db entries refer to files. Allow spaces in these file names. Also treat as comments lines beginning with "--". These are pretty minor fixes in a feature that up 'til now has been essentially unused (witness no bug report about it), so there's very low risk here. If we can get this into 8.0.2 then cabal can start generating the .ghc.environment files, otherwise it cannot as it needs the working package-db entries, to be able to refer to local package dbs in the build tree (or cabal nix store). Test Plan: Manually create example .ghc.env files run ghci; :show packages Done this. It works. Reviewers: austin, bgamari Reviewed By: bgamari Subscribers: thomie Differential Revision: https://phabricator.haskell.org/D2476
* Tag pointers in interpreted constructorsmniip2016-08-3011-16/+105
| | | | | | | | | | | | | | | | | | | | | Instead of stg_interp_constr_entry there are now 7 functions (one for each value of the tag bits) that tag the constructor pointer before returning. This is consistent with compiled constructors' entry code, and expectations that compiled code places on compiled constructors. The iserv protocol is extended with an extra field that explains what pointer tag the constructor should use. Test Plan: Added tests for #12523 Reviewers: erikd, bgamari, hvr, austin, simonmar Reviewed By: simonmar Subscribers: osa1, thomie, rwbarton Differential Revision: https://phabricator.haskell.org/D2473 GHC Trac Issues: #12523
* Fix binary-trees regression from unnecessary floating in CorePrep.Edward Z. Yang2016-08-304-12/+76
| | | | | | | | | | | | | | | | | | In the previous patch, I handled lazy @(Int -> Int) f x correctly, but failed to handle lazy @Int (f x) (we need to collect arguments in f x). Signed-off-by: Edward Z. Yang <ezyang@cs.stanford.edu> Test Plan: validate Reviewers: simonpj, austin, bgamari, nomeata Reviewed By: nomeata Subscribers: simonmar, thomie Differential Revision: https://phabricator.haskell.org/D2471
* Clarify pkg selection when multiple versions are availableHarendra Kumar2016-08-302-122/+159
| | | | | | | | | | Reviewers: austin, bgamari, ezyang Reviewed By: ezyang Subscribers: thomie Differential Revision: https://phabricator.haskell.org/D2464
* Fix and complete runghc documentationHarendra Kumar2016-08-302-15/+44
| | | | | | | | | | Reviewers: austin, thomie, bgamari Reviewed By: bgamari Differential Revision: https://phabricator.haskell.org/D2463 GHC Trac Issues: #12517
* TcGenDeriv: TypofixRyan Scott2016-08-301-1/+1
| | | | I think someone accidentally a word in a Note in TcGenDeriv.
* OccName: Remove unused DrIFT directiveRyan Scott2016-08-301-1/+0
|
* rts: enable parallel GC scan of large (32M+) allocation areaSergei Trofimovich2016-08-302-3/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Parallel GC does not scan large allocation area (-A) effectively as it does not do work stealing from nursery by default. That leads to large imbalance when only one of threads overflows allocation area: most of GC threads finish quickly (as there is not much to collect) and sit idle waiting while single GC thread finishes scan of single allocation area for that thread. The patch enables work stealing for (equivalent of -qb0) allocation area of -A32M or higher. Tested on a highlighting-kate package from Trac #9221 On 8-core machine the difference is around 5% faster of wall-clock time. On 24-core VM the speedup is 20%. Signed-off-by: Sergei Trofimovich <siarheit@google.com> Test Plan: measured wall time and GC parallelism on highlighting-kate build Reviewers: austin, bgamari, erikd, simonmar Reviewed By: bgamari, simonmar Subscribers: thomie Differential Revision: https://phabricator.haskell.org/D2483 GHC Trac Issues: #9221
* GhcMake: limit Capability count to CPU count in parallel modeSergei Trofimovich2016-08-301-1/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | In Trac #9221 one of problems using high --jobs=<N> is amount of mutator (or GC) threads we crate. We use userspace spinning-and-yielding (see ACQUIRE_SPIN_LOCK) to acess work stealing queues. In case of N-worker-threads > N-CPUs fraction of time when thread holding spin lock gets descheduled by kernel increases. That causes other threads to waste CPU time before giving up CPU. Signed-off-by: Sergei Trofimovich <siarheit@google.com> Test Plan: ghc --make -j8 and -j80 have comparable sys time on a 8-core system. Reviewers: austin, gintas, bgamari, simonmar Reviewed By: bgamari, simonmar Subscribers: thomie Differential Revision: https://phabricator.haskell.org/D2482 GHC Trac Issues: #9221
* Missing stderr for T12531.Edward Z. Yang2016-08-301-0/+9
| | | | Signed-off-by: Edward Z. Yang <ezyang@cs.stanford.edu>
* Remove unused DerivInst constructor for DerivStuffRyan Scott2016-08-292-16/+11
| | | | | | | | | | | | | | | | | | | | | | Summary: Back when derived `Generic` instances used to generate auxiliary datatypes, they would also generate instances for those datatypes. Nowadays, GHC generics uses a `DataKinds`-based encoding that requires neither auxiliary datatypes (corresponding to the `DerivTyCon` constructor of `DerivStuff`) nor instances for them (the `DerivInst` constructor of `DerivStuff`). It appears that `DerivTyCon` constructor was removed at some point, but `DerivInst` never was. No `DerivInst` values are ever constructed, so we can safely remove it. Test Plan: It builds Reviewers: austin, hvr, bgamari Reviewed By: bgamari Subscribers: thomie Differential Revision: https://phabricator.haskell.org/D2481
* Fix broken Haddock commentRyan Scott2016-08-291-1/+1
|
* Template Haskell support for TypeApplicationsRyan Scott2016-08-2912-31/+78
| | | | | | | | | | | | | | | | Summary: Fixes #12530. Test Plan: make test TEST=12530 Reviewers: austin, bgamari, hvr, goldfire Reviewed By: goldfire Subscribers: thomie Differential Revision: https://phabricator.haskell.org/D2472 GHC Trac Issues: #12530
* Typofix in docs.Edward Z. Yang2016-08-281-1/+1
| | | | Signed-off-by: Edward Z. Yang <ezyang@cs.stanford.edu>
* Fix scoping of type variables in instancesSimon Peyton Jones2016-08-266-35/+78
| | | | | | | | | | | | | | This fixes Trac #12531: class Foo x where foo :: forall a . x a -> x a default foo :: forall b . x b -> x b foo x = go where go :: x b go = undefined We want 'b' to scope over the code for 'foo', but we were using 'a' instead.
* Move import to avoid warningSimon Peyton Jones2016-08-261-1/+1
| | | | The import of UniqFM in HscTypes was only needed in stage2
* Allow typed holes to be levity-polymorphicSimon Peyton Jones2016-08-264-4/+12
| | | | | | This one-line change fixes Trac #12531. Hooray. Simple, non-invasive; can merge to 8.0.2
* Fix doc build inconsistencyHarendra Kumar2016-08-251-0/+1
| | | | | | | | | | | | | | Remove the doc targets completely not partially when disabled. Otherwise even though we are able to build the targets but we will see some strange errors. Reviewers: austin, bgamari Reviewed By: bgamari Subscribers: thomie Differential Revision: https://phabricator.haskell.org/D2470
* WwLib: Add strictness signature to "let x = absentError …"Joachim Breitner2016-08-252-8/+15
| | | | | indicating that it is bottom. This should help making the "empty cases" lint error give less false alarms.
* Degrade "case scrutinee not known to diverge for sure" Lint error to warningJoachim Breitner2016-08-251-1/+1
| | | | | as proposed in #12435, as it easily gets in the way of development when it reports false positives.