summaryrefslogtreecommitdiff
path: root/testsuite
Commit message (Collapse)AuthorAgeFilesLines
* Name worker threads using pthread_setname_npSimon Marlow2014-10-101-1/+1
| | | | | This helps identify threads in gdb particularly in processes with a lot of threads.
* Make the linker more robust to errorsSimon Marlow2014-10-086-7/+142
| | | | | | | | | | | | | | | | | | | | Summary: When linking fails because there was a problem with the supplied object file, then we should not barf() or exit, we should emit a suitable error message and return an error code to the caller. We should also free all memory that might have been allocated during linking, and generally not do any damage. This patch fixes most common instances of this problem. Test Plan: validate Reviewers: rwbarton, austin, ezyang Reviewed By: ezyang Subscribers: simonmar, ezyang, carter, thomie Differential Revision: https://phabricator.haskell.org/D294
* Preemptive performance number updatesJoachim Breitner2014-10-082-4/+8
|
* Update T4801 perf numbersJoachim Breitner2014-10-081-2/+4
|
* Bump haddock.base perf numbersReid Barton2014-10-071-1/+2
| | | | | | We were so close to the max that the test failed if the pathname to the GHC repository was more than a few dozen characters, causing the haddock.base test to fail on Phab but not locally.
* testsuite: T5486 requires integer-gmp internalsSergei Trofimovich2014-10-071-1/+1
| | | | Signed-off-by: Sergei Trofimovich <slyfox@gentoo.org>
* Add support for LINE pragma in template-haskellEric Mertens2014-10-073-0/+15
| | | | | | | | | | | | | | | | | | Summary: Provide a way to generate {-# LINE #-} pragmas when generating Decs in Template Haskell. This allows more meaningful line numbers to be reported in compile-time errors for dynamically generated code. Test Plan: Run test suite Reviewers: austin, hvr Reviewed By: austin Subscribers: hvr, simonmar, ezyang, carter, thomie Differential Revision: https://phabricator.haskell.org/D299
* Delete __GLASGOW_HASKELL__ ifdefs for stage0 < 7.6.Thomas Miedema2014-10-0711-59/+0
| | | | | | | | | | | | | | | | Summary: My understanding is that ghc 7.10 should be buildable with the last 3 versions of ghc, i.e 7.6, 7.8 and 7.10 itself. Test Plan: x Reviewers: austin Reviewed By: austin Subscribers: hvr, simonmar, ezyang, carter, thomie Differential Revision: https://phabricator.haskell.org/D254
* Merge branch 'master' of http://git.haskell.org/ghcSimon Peyton Jones2014-10-0715-158/+200
|\
| * testsuite: fix seward-space-leak build aganst Prelude/Main 'traverse' clashSergei Trofimovich2014-10-061-0/+2
| | | | | | | | Signed-off-by: Sergei Trofimovich <slyfox@gentoo.org>
| * testsuite: fix T1735_Help/State.hs build failure (AMP)Sergei Trofimovich2014-10-061-0/+10
| | | | | | | | Signed-off-by: Sergei Trofimovich <slyfox@gentoo.org>
| * testsuite: fix T5751 build failure (AMP)Sergei Trofimovich2014-10-061-1/+1
| | | | | | | | Signed-off-by: Sergei Trofimovich <slyfox@gentoo.org>
| * testsuite: fix tcrun036 build against Prelude/Main 'traverse' clashSergei Trofimovich2014-10-061-0/+2
| | | | | | | | Signed-off-by: Sergei Trofimovich <slyfox@gentoo.org>
| * Restore spaces instead of tabs, caused by revert of Python 3Krzysztof Gogolewski2014-10-033-7/+7
| | | | | | | | The git hook does not allow to reinsert tabs.
| * Revert "Basic Python 3 support for testsuite driver (Trac #9184)"Krzysztof Gogolewski2014-10-0314-164/+192
| | | | | | | | | | | | This reverts commit 084d241b316bfa12e41fc34cae993ca276bf0730. This is a possible culprit of Windows breakage reported at ghc-devs.
* | Use correct precedence when printing contexts with class operatorsSimon Peyton Jones2014-10-0718-90/+97
|/ | | | Fixes Trac #9658
* Rename _closure to _static_closure, apply naming consistently.Edward Z. Yang2014-10-011-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: In preparation for indirecting all references to closures, we rename _closure to _static_closure to ensure any old code will get an undefined symbol error. In order to reference a closure foobar_closure (which is now undefined), you should instead use STATIC_CLOSURE(foobar). For convenience, a number of these old identifiers are macro'd. Across C-- and C (Windows and otherwise), there were differing conventions on whether or not foobar_closure or &foobar_closure was the address of the closure. Now, all foobar_closure references are addresses, and no & is necessary. CHARLIKE/INTLIKE were not changed, simply alpha-renamed. Part of remove HEAP_ALLOCED patch set (#8199) Depends on D265 Signed-off-by: Edward Z. Yang <ezyang@mit.edu> Test Plan: validate Reviewers: simonmar, austin Subscribers: simonmar, ezyang, carter, thomie Differential Revision: https://phabricator.haskell.org/D267 GHC Trac Issues: #8199
* Basic Python 3 support for testsuite driver (Trac #9184)Krzysztof Gogolewski2014-10-0114-192/+164
| | | | | | | | | | | | | | | | | | | | | | | | Summary: Most of the changes is adaptation of old Python 2 only code. My priority was not breaking Python 2, and so I avoided bigger changes to the driver. In particular, under Python 3 the output is a str and buffering cannot be disabled. To test, define PYTHON=python3 in testsuite/mk/boilerplate.mk. Thanks to aspidites <emarshall85@gmail.com> who provided the initial patch. Test Plan: validate under 2 and 3 Reviewers: hvr, simonmar, thomie, austin Reviewed By: thomie, austin Subscribers: aspidites, thomie, simonmar, ezyang, carter Differential Revision: https://phabricator.haskell.org/D233 GHC Trac Issues: #9184
* Extend `Foldable` class with `length` and `null` methodsHerbert Valerio Riedel2014-09-287-10/+17
| | | | | | | | | | | | | This completes the `Foldable` class by two important operations which this way can be optimised for the underlying structure more easily. A minor fix for the `containers` submodule was needed to due name clash Addresses #9621 Reviewed By: ekmett, dfeuer, austin Differential Revision: https://phabricator.haskell.org/D250
* Don't re-export `Alternative(..)` from Control.Monad (re #9586)Herbert Valerio Riedel2014-09-262-2/+3
| | | | | | | | | | | | | | | | | This was done in d94de87252d0fe2ae97341d186b03a2fbe136b04 to avoid orphans but since a94dc4c3067c6a0925e2e39f35ef0930771535f1 moved `Alternative` into GHC.Base, this isn't needed anymore. This is important, as otherwise this would require a non-neglectable amount of `Control.Monad hiding ((<|>), empty)` imports in user code. The Haddock submodule is updated as well Test Plan: partial local ./validate --fast, let Harbormaster doublecheck it Reviewed By: ekmett, austin Differential Revision: https://phabricator.haskell.org/D248
* This test should have -XDataKindsSimon Peyton Jones2014-09-261-1/+1
|
* Complain about illegal type literals in renamer, not parserSimon Peyton Jones2014-09-265-2/+9
| | | | | | A premature complaint was causing Trac #9634. Acutally this change also simplifies the lexer and eliminates duplication. (The renamer was already making the check, as it happens.)
* Two improved error messagesSimon Peyton Jones2014-09-262-8/+25
| | | | | I'm not quite sure why these have improved following the previous four commits, but I'm quite happy about it
* Improve error messages from functional dependenciesSimon Peyton Jones2014-09-268-30/+93
| | | | | | | | | | | | Reponding to Trac #9612: * Track the CtOrigin of a Derived equality, arising from a functional dependency * And report it clearly in the error stream This relies on a previous commit, in which I stop dropping Derived insolubles on the floor.
* Wibble to implicit-parameter error messageSimon Peyton Jones2014-09-262-10/+12
|
* Do not discard insoluble Derived constraintsSimon Peyton Jones2014-09-2615-104/+106
| | | | | | | | | | | | | | | | | | This is preparing for a fix to Trac #9612. The idea is that insoluble constraints are nice solid errors that we should not discard before we have a chance to report them. So TcRnTypes.dropDerivedWC now keeps insoluble Derived constrains, and instead TcSimplify.solve_wanteds filters them out We get somewhat better error message for kind-equality failures too. A slight downside is that to avoid *duplicate* kind-equality failures when we float a kind-incompatible equality (e.g. alpha:* ~ Int#), I've disabled constraint-floating when there are insolubles. But that in turn makes a handful of error messages a little less informative; good examples are mc21, mc22, mc25. But I am re-jigging the constraint floating machinery in another branch, which will make this go back to the way it was before.
* Defer errors in derived instancesSimon Peyton Jones2014-09-266-2/+24
| | | | Fixes Trac #9576. Turned out to be pretty easy.
* `M-x delete-trailing-whitespace` & `M-x untabify`Herbert Valerio Riedel2014-09-241-7/+7
|
* Update Cabal submodule & ghc-pkg to use new module re-export typesEdward Z. Yang2014-09-244-12/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: The main change is that Cabal changed the representation of module re-exports to distinguish reexports in source .cabal files versus re-exports in installed package registraion files. Cabal now also does the resolution of re-exports to specific installed packages itself, so ghc-pkg no longer has to do this. This is a cleaner design overall because re-export resolution can fail so it is better to do it during package configuration rather than package registration. It also simplifies the re-export representation that ghc-pkg has to use. Add extra ghc-pkg sanity check for module re-exports and duplicates For re-exports, check that the defining package exists and that it exposes the defining module (or for self-rexport exposed or hidden modules). Also check that the defining package is actually a direct or indirect dependency of the package doing the re-exporting. Also add a check for duplicate modules in a package, including re-exported modules. Test Plan: So far the sanity checks are totally untested. Should add some test case to make sure the sanity checks do catch things correctly, and don't ban legal things. Reviewers: austin, duncan Subscribers: angerman, simonmar, ezyang, carter Differential Revision: https://phabricator.haskell.org/D183 GHC Trac Issues:
* Change all hashbangs to /usr/bin/env (#9057)Thomas Miedema2014-09-231-1/+1
| | | | | | | | | | | | | | | | | | Summary: ``` git grep -l '#!' | xargs sed -i 's|#!.*/bin/\([^ ]*\)$|#!/usr/bin/env \1|' ``` and some manual tweaking Test Plan: harbormaster Reviewers: austin Subscribers: hvr, simonmar, ezyang, carter Differential Revision: https://phabricator.haskell.org/D237 GHC Trac Issues: #9057
* Delete all /* ! __GLASGOW_HASKELL__ */ codeThomas Miedema2014-09-231-37/+31
| | | | | | | | | | | | | | | | | Summary: ``` git grep -l '\(#ifdef \|#if defined\)(\?__GLASGOW_HASKELL__)\?' ``` Test Plan: validate Reviewers: rwbarton, hvr, austin Reviewed By: rwbarton, hvr, austin Subscribers: rwbarton, simonmar, ezyang, carter Differential Revision: https://phabricator.haskell.org/D218
* Test Trac #9565 and #9583Simon Peyton Jones2014-09-233-0/+44
|
* Export `Monoid(..)`/`Foldable(..)`/`Traversable(..)` from PreludeHerbert Valerio Riedel2014-09-2110-10/+22
| | | | | | | | | | | | | | | This finally exposes also the methods of these 3 classes in the Prelude in order to allow to define basic class instances w/o needing imports. This almost completes the primary goal of #9586 NOTE: `fold`, `foldl'`, `foldr'`, and `toList` are not exposed yet, as they require upstream fixes for at least `containers` and `bytestring`, and are not required for defining basic instances. Reviewed By: ekmett, austin Differential Revision: https://phabricator.haskell.org/D236
* Generalise Data.List/Control.Monad to Foldable/TraversableHerbert Valerio Riedel2014-09-211-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | This flips the switch and replaces the entities in `Data.List`/`Control.Monad` conflicting with `Data.{Foldable,Traversable}` with re-exports of the more general versions. As of this commit, the code below (which is also added as a test-case) compiles w/o error. module XPrelude (module X) where import Control.Monad as X import Data.Foldable as X import Data.List as X import Data.Monoid as X import Data.Traversable as X import Prelude as X This addresses #9568 Reviewed By: ekmett, austin Differential Revision: https://phabricator.haskell.org/D235
* Move `mapM` and `sequence` to GHC.Base and break import-cyclesHerbert Valerio Riedel2014-09-211-2/+2
| | | | | | | | | | This simplifies the import graph and more importantly removes import cycles that arise due to `Control.Monad` & `Data.List` importing `Data.Traversable` (preparation for #9586) Reviewed By: ekmett, austin Differential Revision: https://phabricator.haskell.org/D234
* Generalise (some of) Data.List to Foldables (re #9568)Herbert Valerio Riedel2014-09-202-4/+4
| | | | | | | | | | | | | | | | | | This replaces the entities in Data.List conflicting with Data.Foldable with re-exports of the generalised version from Data.Foldable. As of this commit, the following compiles w/o error module XPrelude (module X) where import Control.Monad as X import Data.Foldable as X import Data.List as X import Prelude as X Reviewed By: austin, dfeuer, ekmett Differential Revision: https://phabricator.haskell.org/D229
* Set up framework for generalising Data.List to FoldablesHerbert Valerio Riedel2014-09-205-3/+8
| | | | | | | | | | | | | | | | | | | | | This renames the Data.List module to Data.OldList, and puts a new Data.List module into its place re-exporting all list functions. The plan is to leave the monomorphic versions of the list functions in Data.OldList to help smooth the transition. The new Data.List module then will simply re-export entities from Data.OldList and Data.Foldable. This refactoring has been placed in a separate commit to be able to better isolate any regressions caused by the actual list function generalisations when implementing #9586 This also updates the haskell2010, haskell98, and array submodules Reviewed By: austin, ekmett Differential Revision: https://phabricator.haskell.org/D228
* Change linker message verbosity to `-v2` (re #7863)Herbert Valerio Riedel2014-09-202-8/+0
| | | | | | | | | | | | | | | | With this change, the linker status logging output such as Loading package ghc-prim ... linking ... done. Loading package integer-gmp ... linking ... done. Loading package base ... linking ... done. is suppressed unless verbosity level is `-v2` or higher. This is done to reduce the compiler message noise when TH is involved, which can reduce the visibiliy of compile warnings. Reviewed By: ekmett, austin Differential Revision: https://phabricator.haskell.org/D232
* Deactive T4801 `max_bytes_used`-check & bump T3064 numbersHerbert Valerio Riedel2014-09-201-22/+27
| | | | | | | | | T4801 is deactived for now because it's currently too volatile and causes too much noise in Phabricator's CI Reviewed By: austin Differential Revision: https://phabricator.haskell.org/D230
* Clean up Coercible handling, and interaction of data families with newtypesSimon Peyton Jones2014-09-195-1/+25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch fixes Trac #9580, in which the Coercible machinery succeeded even though the relevant data constructor was not in scope. As usual I got dragged into a raft of refactoring changes, all for the better. * Delete TcEvidence.coercionToTcCoercion (now unused) * Move instNewTyConTF_maybe, instNewTyCon_maybe to FamInst, and rename them to tcInstNewTyConTF_maybe, tcInstNewTyCon (They both return TcCoercions.) * tcInstNewTyConTF_maybe also gets more convenient type, which improves TcInteract.getCoercibleInst * Define FamInst.tcLookupDataFamInst, and use it in TcDeriv, (as well as in tcInstNewTyConTF_maybe) * Improve error report for Coercible errors, when data familes are involved Another use of tcLookupDataFamInst * In TcExpr.tcTagToEnum, use tcLookupDataFamInst to replace local hacky code * Fix Coercion.instNewTyCon_maybe and Type.newTyConInstRhs to deal with eta-reduced newtypes, using (new) Type.unwrapNewTyConEtad_maybe and (new) Type.applyTysX Some small refactoring of TcSMonad.matchFam.
* Increase -fcontext-stack=N default to 100Simon Peyton Jones2014-09-191-7/+13
| | | | This addresses Trac #5395
* Auto-derive a few manually coded Show instancesHerbert Valerio Riedel2014-09-191-1/+1
| | | | | | | | | | | | | | | | | In `base`, the instances instance Show () instance Show Bool instance Show Ordering instance Show a => Show (Maybe a) where defined manually, even though we can leverage GHC's auto-deriver which is perfectly capable by standalone derivation to avoid boiler-plate code such as this. Reviewed By: austin Differential Revision: https://phabricator.haskell.org/D219
* Add -fwarn-context-quantification (#4426)Krzysztof Gogolewski2014-09-187-8/+66
| | | | | | | | | | | | | | | | | | | | | | Summary: This warning (enabled by default) reports places where a context implicitly binds a type variable, for example type T a = {-forall m.-} Monad m => a -> m a Also update Haddock submodule. Test Plan: validate Reviewers: hvr, goldfire, simonpj, austin Reviewed By: austin Subscribers: simonmar, ezyang, carter Differential Revision: https://phabricator.haskell.org/D211 GHC Trac Issues: #4426
* Generalise Control.Monad.{sequence_,msum,mapM_,forM_}Herbert Valerio Riedel2014-09-181-1/+4
| | | | | | | | | | | | | | | | This finally takes the gloves off, and performs the first actual generalization in order to implement #9586. This re-exports the respective definitions for the 4 combinators defined in Data.Foldable. This way, importing Data.Foldable and Control.Monad unqualified won't bring conflicting definitions of those 4 entities into scope anymore. This change seems to have some minor effect on rule-firing, which causes some wibble in the test-case T4007 Reviewed By: ekmett, austin Differential Revision: https://phabricator.haskell.org/D226
* Move Applicative/MonadPlus into GHC.BaseHerbert Valerio Riedel2014-09-183-6/+6
| | | | | | | | | | | This is necessary in order to invert the import-dependency between Data.Foldable and Control.Monad (for addressing #9586) This also updates the `binary` submodule to qualify a GHC.Base import Reviewed By: austin Differential Revision: https://phabricator.haskell.org/D223
* Move `Maybe`-typedef into GHC.BaseHerbert Valerio Riedel2014-09-1614-64/+64
| | | | | | | This is preparatory work for reintroducing SPECIALISEs that were lost in d94de87252d0fe2ae97341d186b03a2fbe136b04 Differential Revision: https://phabricator.haskell.org/D214
* Add the ability to :set -l{foo} in ghci, fix #1407.archblob2014-09-162-0/+6
| | | | | | | | | | | | | | | | | | Summary: The dynamic linking code was already there but it was not called on flag changes in ghci. Test Plan: validate Reviewers: hvr, simonmar, austin Reviewed By: austin Subscribers: simonmar, ezyang, carter Differential Revision: https://phabricator.haskell.org/D194 GHC Trac Issues: #1407
* Remove special casing of singleton strings, split all strings.Thijs Alkemade2014-09-163-0/+55
| | | | | | | | | | | | | | | | | | | | | Summary: exprIsConApp_maybe now detects string literals and correctly splits them. This means case-statemnts on string literals can now push the literal into the cases. fix trac issue #9400 Test Plan: validate Reviewers: austin, simonpj Reviewed By: austin, simonpj Subscribers: simonmar, ezyang, carter Differential Revision: https://phabricator.haskell.org/D199 GHC Trac Issues: #9400
* Fix cppcheck warningsBoris Egorov2014-09-161-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: Cppcheck found a few defects in win32 IOManager and a typo in rts testsuite. This commit fixes them. Cppcheck 1.54 founds three possible null pointer dereferences of ioMan pointer. It is dereferenced and checked for NULL after that. testheapalloced.c contains typo in printf statement, which should print percent sign but treated as parameter placement by compiler. To properly print percent sign one need to use "%%" string. FYI: Cppcheck 1.66 cannot find possible null pointer dereferences in mentioned places, mistakenly thinking that some memory leaking instead. I probably fill a regression bug to Cppcheck. Test Plan: Build project, run 'make fulltest'. It finished with 28 unexpected failures. I don't know if they are related to my fix. Unexpected results from: TEST="T3500b T7891 tc124 T7653 T5321FD T5030 T4801 T6048 T5631 T5837 T5642 T9020 T3064 parsing001 T1969 T5321Fun T783 T3294" OVERALL SUMMARY for test run started at Tue Sep 9 16:46:27 2014 NOVT 4:23:24 spent to go through 4101 total tests, which gave rise to 16075 test cases, of which 3430 were skipped 315 had missing libraries 12154 expected passes 145 expected failures 3 caused framework failures 0 unexpected passes 28 unexpected failures Unexpected failures: ../../libraries/base/tests T7653 [bad exit code] (ghci,threaded1,threaded2) perf/compiler T1969 [stat not good enough] (normal) perf/compiler T3064 [stat not good enough] (normal) perf/compiler T3294 [stat not good enough] (normal) perf/compiler T4801 [stat not good enough] (normal) perf/compiler T5030 [stat not good enough] (normal) perf/compiler T5321FD [stat not good enough] (normal) perf/compiler T5321Fun [stat not good enough] (normal) perf/compiler T5631 [stat not good enough] (normal) perf/compiler T5642 [stat not good enough] (normal) perf/compiler T5837 [stat not good enough] (normal) perf/compiler T6048 [stat not good enough] (optasm) perf/compiler T783 [stat not good enough] (normal) perf/compiler T9020 [stat not good enough] (optasm) perf/compiler parsing001 [stat not good enough] (normal) typecheck/should_compile T7891 [exit code non-0] (hpc,optasm,optllvm) typecheck/should_compile tc124 [exit code non-0] (hpc,optasm,optllvm) typecheck/should_run T3500b [exit code non-0] (hpc,optasm,threaded2,dyn,optllvm) Reviewers: austin Reviewed By: austin Subscribers: simonmar, ezyang, carter Differential Revision: https://phabricator.haskell.org/D203
* Mark T8639_api/T8628 as PHONYEdward Z. Yang2014-09-151-1/+1
| | | | Signed-off-by: Edward Z. Yang <ezyang@cs.stanford.edu>