summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* When calling the success continuation of a matcher, pass existential tyvarswip/T9732Dr. ERDI Gergo2014-11-131-3/+3
| | | | as type arguments, not value arguments
* nlHsTyApps: for applying a function both on type- and term-level argumentsDr. ERDI Gergo2014-11-131-1/+4
|
* Apply compulsory unfoldings during desugaring, except for `seq` which is ↵Dr. ERDI Gergo2014-11-131-1/+21
| | | | | | special. See Note [Unfolding while desugaring] for the rationale.
* If pattern synonym is bidirectional and its type is some unboxed type T#,Dr. ERDI Gergo2014-11-1320-87/+228
| | | | | generate a worker function of type Void# -> T#, and redirect the wrapper (via a compulsory unfolding) to the worker. Fixes #9732.
* Binding things matched by an unboxed pattern synonym should require a bangDr. ERDI Gergo2014-11-135-1/+28
|
* Fix typo in panic messageDr. ERDI Gergo2014-11-131-1/+1
|
* Improve `Foldable` instance for `Array`David Feuer2014-11-135-6/+214
| | | | | | | | | | | | | | | | | | | | Previously, `Array`s were simply converted to lists, and the list methods used. That works acceptably well for `foldr` and `foldr1`, but not so sensibly for most other things. Left folds ended up "twisted" the way they are for lists, leading to surprising performance characteristics. Moreover, this implements `length` and `null` so they check the array size directly. Finally, a test is added to the testsuite ensuring the overridden `Foldable` methods agree with their expected default semantics. Addresses #9763 Reviewed By: hvr, austin Differential Revision: https://phabricator.haskell.org/D459
* base: define `sequence = mapM id`David Feuer2014-11-131-3/+19
| | | | | | | | | | | | | | | | This avoids duplication in `GHC.Base`; originally, we had mapM f = sequence . map f This led to excessive allocation in `cryptarithm2`. Defining sequence = mapM id does not appear to cause any `nofib` problems. Reviewed By: hvr Differential Revision: https://phabricator.haskell.org/D470
* Make unwords and words fuse somewhatDavid Feuer2014-11-131-4/+43
| | | | | | | | | | | | | Make `words` a good producer and `unwords` a good consumer for list fusion. Thus `unwords . words` will avoid producing an intermediate list of words, although it will produce each individual word. Make `unwords` slightly lazier, so that `unwords (s : undefined) = s ++ undefined` instead of `= undefined`. Reviewed By: austin Differential Revision: https://phabricator.haskell.org/D375
* base: Fix map/coerce commentDavid Feuer2014-11-131-3/+2
| | | | | | | | | Make the comment on the map/coerce rule refer to the right section in the paper; give the full name of the papers, and name its authors. [skip ci] Differential Revision: https://phabricator.haskell.org/D472
* Update userguide for new `-fwarn-trustworthy-safe` flag.David Terei2014-11-123-3/+59
|
* Add `--fwarn-trustworthy-safe` to `-Wall`David Terei2014-11-1210-1/+23
| | | | | Update submodule haskell2010, haskell98, hoop, hpc and stm to fix new warnings.
* Add in `-fwarn-trustworthy-safe` flag.David Terei2014-11-1238-62/+397
| | | | | This warns when a module marked as `-XTrustworthy` could have been inferred as safe instead.
* Remove a stray Trustworthy flag in ghc.David Terei2014-11-121-1/+0
|
* includes/Stg.h: define _DEFAULT_SOURCE for glibc-2.20Sergei Trofimovich2014-11-121-0/+4
| | | | | | | | | | | | | | | | | | | | | | _BSD_SOURCE we are using for 'gamma()' and friends was deprecated in glibc-2.20 in favour of '_DEFAULT_SOURCE'. gcc says: In file included from /usr/include/math.h:26:0: 0, from includes/Stg.h:69, from /tmp/ghc19488_0/ghc19488_2.hc:3: /usr/include/features.h:148:3: warning: #warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE" [-Wcpp] # warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE" ^ Patch fixes testsuite failures on UNREG (stderr are not cluttered by warnings anymore). Signed-off-by: Sergei Trofimovich <slyfox@gentoo.org>
* Fix #9404 by removing tcInfExpr.Richard Eisenberg2014-11-129-61/+79
| | | | | | See the ticket for more info about the new algorithm. This is a small simplification, unifying the treatment of type checking in a few similar situations.
* Testsuite wibble due to #9404Richard Eisenberg2014-11-125-10/+12
| | | | [skip ci]
* Test #9404 (typecheck/should_compile/T9404 and T9404b)Richard Eisenberg2014-11-123-0/+23
|
* Fix #9788 by giving `coerce` the right type.Richard Eisenberg2014-11-122-14/+9
| | | | | No test case added, as the original mistake is just one level up from a typo.
* Testsuite wibbles due to #9204Richard Eisenberg2014-11-125-4/+21
|
* Fix #9204 by outputting extra info on boot file mismatch.Richard Eisenberg2014-11-122-49/+135
| | | | [skip ci] -- testsuite wibbles are in next commit
* Test #9204 in roles/should_fail/T9204Richard Eisenberg2014-11-125-1/+25
|
* Fix #9064 by adding support for generic default signatures to TH.Richard Eisenberg2014-11-128-17/+39
|
* Test #9064 in th/T9064Richard Eisenberg2014-11-123-0/+31
|
* Fix #8100, by adding StandaloneDerivD to TH's Dec type.Richard Eisenberg2014-11-127-22/+56
|
* Test #8100 in th/T8100Richard Eisenberg2014-11-122-0/+21
|
* Derive Generic for TH types (#9527)Richard Eisenberg2014-11-121-41/+42
|
* Remove unboxed Int# fields from NameFlavour (#9527)Richard Eisenberg2014-11-123-102/+21
|
* Untabify template-haskell.Richard Eisenberg2014-11-125-51/+51
|
* Fix #9066.Richard Eisenberg2014-11-124-30/+58
| | | | | | | | | | When splicing in a fixity declaration, look for both term-level things and type-level things. This requires some changes elsewhere in the code to allow for more flexibility when looking up Exact names, which can be assigned the wrong namespace during fixity declaration conversion. See the ticket for more info.
* Test #9066 in th/T9066Richard Eisenberg2014-11-122-0/+12
|
* fix allocLimit3 on WindowsSimon Marlow2014-11-121-1/+6
|
* Fix build errors on Windows (these tests still don't work though)Simon Marlow2014-11-122-0/+6
|
* Per-thread allocation counters and limitsSimon Marlow2014-11-1237-168/+675
| | | | | | | | This reverts commit f0fcc41d755876a1b02d1c7c79f57515059f6417. New changes: now works on 32-bit platforms too. I added some basic support for 64-bit subtraction and comparison operations to the x86 NCG.
* Implement new integer-gmp2 from scratch (re #9281)Herbert Valerio Riedel2014-11-1240-18/+6103
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is done as a separate `integer-gmp2` backend library because it turned out to become a complete rewrite from scratch. Due to the different (over)allocation scheme and potentially different accounting (via the new `{shrink,resize}MutableByteArray#` primitives), some of the nofib benchmarks actually results in increased allocation numbers (but not necessarily an increase in runtime!). I believe the allocation numbers could improve if `{resize,shrink}MutableByteArray#` could be optimised to reallocate in-place more efficiently. Here are the more apparent changes in the latest nofib comparision between `integer-gmp` and `integer-gmp2`: ------------------------------------------------------------------ Program Size Allocs Runtime Elapsed TotalMem ------------------------------------------------------------------ ... bernouilli +1.6% +15.3% 0.132 0.132 0.0% ... cryptarithm1 -2.2% 0.0% -9.7% -9.7% 0.0% ... fasta -0.7% -0.0% +10.9% +10.9% 0.0% ... kahan +0.6% +38.9% 0.169 0.169 0.0% ... lcss -0.7% -0.0% -6.4% -6.4% 0.0% ... mandel +1.6% +33.6% 0.049 0.049 0.0% ... pidigits +0.8% +8.5% +3.9% +3.9% 0.0% power +1.4% -23.8% -18.6% -18.6% -16.7% ... primetest +1.3% +50.1% 0.085 0.085 0.0% ... rsa +1.6% +53.4% 0.026 0.026 0.0% ... scs +1.2% +6.6% +6.5% +6.6% +14.3% ... symalg +1.0% +9.5% 0.010 0.010 0.0% ... transform -0.6% -0.0% -5.9% -5.9% 0.0% ... ------------------------------------------------------------------ Min -2.3% -23.8% -18.6% -18.6% -16.7% Max +1.6% +53.4% +10.9% +10.9% +14.3% Geometric Mean -0.3% +1.9% -0.8% -0.8% +0.0% (see P35 / https://phabricator.haskell.org/P35 for full report) By default, `INTEGER_LIBRARY=integer-gmp2` is active now, which results in the package `integer-gmp-1.0.0.0` being registered in the package db. The previous `integer-gmp-0.5.1.0` can be restored by setting `INTEGER_LIBRARY=integer-gmp` (but will probably be removed altogether for GHC 7.12). In-tree GMP support has been stolen from the old `integer-gmp` (while unpatching the custom memory-allocators, as well as forcing `-fPIC`) A minor hack to `ghc-cabal` was necessary in order to support two different `integer-gmp` packages (in different folders) with the same package key. There will be a couple of follow-up commits re-implementing some features that were dropped to keep D82 minimal, as well as further clean-ups/improvements. More information can be found via #9281 and https://ghc.haskell.org/trac/ghc/wiki/Design/IntegerGmp2 Reviewed By: austin, rwbarton, simonmar Differential Revision: https://phabricator.haskell.org/D82
* Disable T4801/peak_megabytes_allocatedHerbert Valerio Riedel2014-11-121-17/+19
| | | | | | This test seems too close to a tipping point (and thus too sensitive to the build-env used) and T4801's `max_bytes_used` was disabled as well some time ago for a similiar reason.
* Add stderr for T9662Simon Peyton Jones2014-11-111-0/+84
|
* Test Trac #7862Simon Peyton Jones2014-11-113-1/+37
|
* Test Trac #9077Simon Peyton Jones2014-11-113-0/+7
|
* Improve documentation of -ticky a littleSimon Peyton Jones2014-11-113-3/+9
|
* Comments onlySimon Peyton Jones2014-11-111-0/+3
|
* Test Trac #9662Simon Peyton Jones2014-11-113-0/+107
|
* Comments only (on recursive dictionaries)Simon Peyton Jones2014-11-112-40/+58
|
* De-bias Data.Foldable and improve docstringsDavid Feuer2014-11-111-26/+132
| | | | | | | | | | | | Use fewer left/right-biased folds for defaults and functions in `Data.Foldable`, to better support things that don't look like cons lists. This also extends the Haddock docstrings in `Data.Foldable`. Reviewed By: hvr, ekmett Differential Revision: https://phabricator.haskell.org/D441
* Define list monad operations using comprehensionsDavid Feuer2014-11-111-7/+44
| | | | | | | | | | | | | | | | Define list monad operations using list comprehensions. Code using monad operations with lists did not fuse fully. Writing list code with `do` notation or `(>>=)` and `(>>)` operations could allocate more than equivalent code using list comprehensions. Define `mapM` directly, instead of using `sequence` and `map`. This leads to substantially less allocation in `cryptarithm2`. Addresses #9781 Reviewed By: ekmett, nomeata Differential Revision: https://phabricator.haskell.org/D455
* Typo fix; Trac #9787Austin Seipp2014-11-101-2/+2
| | | | | | Also, reword :print description. Signed-off-by: Austin Seipp <austin@well-typed.com>
* Move Data.Functor.Identity from transformers to baseHerbert Valerio Riedel2014-11-105-3/+82
| | | | | | | | | | | This also updates the `transformers` submodule to the just released `transformers-0.4.2.0` package version. See #9664 for more details Reviewed By: austin, ekmett Differential Revision: https://phabricator.haskell.org/D313
* Use (.) and id from Base in Control.ApplicativeDavid Feuer2014-11-081-2/+2
| | | | | | | | | Control.Applicative previously imported `(.)` and `id` from `Control.Arrow`, but then only applied them to functions. Reviewed By: ekmett, hvr Differential Revision: https://phabricator.haskell.org/D462
* Unlit overlooked GHC/Conc/Sync.lhsHerbert Valerio Riedel2014-11-081-31/+14
| | | | This is a follow-up commit to df3b1d43cc862fe03f0724a9c0ac9e7cecdf4605
* Group PatSyn req/prov arguments together so that they're not all over the placeDr. ERDI Gergo2014-11-084-29/+28
|