summaryrefslogtreecommitdiff
path: root/compiler/vectorise
Commit message (Collapse)AuthorAgeFilesLines
* Completed the implementation of VECTORISE SCALARManuel M T Chakravarty2011-03-053-154/+174
| | | | | | | | | - The pragma {-# VECTORISE SCALAR foo #-} marks 'foo' as a scalar function for for vectorisation and generates a vectorised version by applying 'scalar_map' and friends. - The set of scalar functions is not yet emitted into interface files. This will be added in a subsequent patch via 'VectInfo'.
* Added a VECTORISE pragmaManuel M T Chakravarty2011-02-2011-245/+367
| | | | | | | | | | | | | | | - Added a pragma {-# VECTORISE var = exp #-} that prevents the vectoriser from vectorising the definition of 'var'. Instead it uses the binding '$v_var = exp' to vectorise 'var'. The vectoriser checks that the Core type of 'exp' matches the vectorised Core type of 'var'. (It would be quite complicated to perform that check in the type checker as the vectorisation of a type needs the state of the VM monad.) - Added parts of a related VECTORISE SCALAR pragma - Documented -ddump-vect - Added -ddump-vt-trace - Some clean up
* Cleaned up Expr and Vectorisekeller@.cse.unsw.edu.au2011-02-152-31/+13
|
* Fixed two syntax errorskeller@.cse.unsw.edu.au2011-02-141-2/+2
|
* Handling of recursive scalar functions in isScalarLamkeller@cse.unsw.edu.au2011-02-143-33/+57
|
* Added handling of non-recursive module global functions to isScalar checkkeller@cse.unsw.edu.au2011-02-093-22/+40
|
* keller@cse.unsw.edu.au2011-02-021-2/+2
|
* Removed minor bugkeller@cse.unsw.edu.au2011-02-021-1/+1
|
* added handling of data constructors to vectLamkeller@cse.unsw.edu.au2011-02-011-17/+48
|
* Fix vectorisation of recursive typesRoman Leshchinskiy2011-01-2612-162/+107
|
* Fix warningsIan Lynagh2010-12-191-3/+0
|
* vectoriser: don't always pass superclass dictionaries to PA dfunsRoman Leshchinskiy2010-12-181-14/+38
| | | | This is just a guess at how this should work.
* vectoriser: delete dead codeRoman Leshchinskiy2010-12-181-20/+1
|
* vectoriser: adapt to new superclass story part I (dictionary construction)Roman Leshchinskiy2010-12-188-47/+127
|
* Remove code that is dead now that we need >= 6.12 to buildIan Lynagh2010-12-151-2/+0
|
* Fix recursive superclasses (again). Fixes Trac #4809.simonpj@microsoft.com2010-12-131-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch finally deals with the super-delicate question of superclases in possibly-recursive dictionaries. The key idea is the DFun Superclass Invariant (see TcInstDcls): In the body of a DFun, every superclass argument to the returned dictionary is either * one of the arguments of the DFun, or * constant, bound at top level To establish the invariant, we add new "silent" superclass argument(s) to each dfun, so that the dfun does not do superclass selection internally. There's a bit of hoo-ha to make sure that we don't print those silent arguments in error messages; a knock on effect was a change in interface-file format. A second change is that instead of the complex and fragile "self dictionary binding" in TcInstDcls and TcClassDcl, using the same mechanism for existential pattern bindings. See Note [Subtle interaction of recursion and overlap] in TcInstDcls and Note [Binding when looking up instances] in InstEnv. Main notes are here: * Note [Silent Superclass Arguments] in TcInstDcls, including the DFun Superclass Invariant Main code changes are: * The code for MkId.mkDictFunId and mkDictFunTy * DFunUnfoldings get a little more complicated; their arguments are a new type DFunArg (in CoreSyn) * No "self" argument in tcInstanceMethod * No special tcSimplifySuperClasss * No "dependents" argument to EvDFunApp IMPORTANT It turns out that it's quite tricky to generate the right DFunUnfolding for a specialised dfun, when you use SPECIALISE INSTANCE. For now I've just commented it out (in DsBinds) but that'll lose some optimisation, and I need to get back to this.
* Fixed some 'unused vars' warningskeller@cse.unsw.edu.au2010-11-301-5/+5
|
* vectScalarLam handles int, float, and double nowkeller@cse.unsw.edu.au2010-11-291-2/+6
|
* Handling of lets, letrec and case when checking if a lambda expr needs to be ↵keller@cse.unsw.edu.au2010-11-151-1/+22
| | | | vectorised
* vectoriser: fix warningBen Lippmeier2010-11-261-1/+0
|
* vectoriser: fix warningBen Lippmeier2010-11-261-1/+0
|
* vectoriser: take class directly from the instance tyconBen Lippmeier2010-11-261-15/+6
|
* vectoriser: comments onlyBen Lippmeier2010-11-251-7/+44
|
* vectoriser: follow changes in mkClassBen Lippmeier2010-11-251-0/+1
|
* vectoriser: tracing wibblesBen Lippmeier2010-11-251-8/+7
|
* mkDFunUnfolding wants the type of the dfun to be a PredTybenl@ouroborus.net2010-09-141-5/+31
|
* vectoriser: fix conflictsBen Lippmeier2010-11-251-3/+3
|
* Comments and formatting onlybenl@ouroborus.net2010-09-141-9/+17
|
* Comments and formatting to type environment vectoriserbenl@ouroborus.net2010-09-091-13/+19
|
* Nicer error message for #3782benl@ouroborus.net2010-10-291-1/+9
| | | | | | | | | | | | | | | | | | It now says: ghc-stage2: sorry! (this is work in progress) (GHC version 7.1.20101028 for i386-apple-darwin): Vectorise.Builtins.indexBuiltin DPH builtin function 'sumTyCon' of size '11' is not yet implemented. This function does not appear in your source program, but it is needed to compile your code in the backend. This is a known, current limitation of DPH. If you want it to to work you should send mail to cvs-ghc@haskell.org and ask what you can do to help (it might involve some GHC hacking). I added 'pprSorry' that behaves like 'pprPanic' except it say sorry! instead of panic!, and doesn't ask the user to report a bug.
* Refactoring and tidyup of HscMain and related things (also fix #1666)Simon Marlow2010-10-272-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | While trying to fix #1666 (-Werror aborts too early) I decided to some tidyup in GHC/DriverPipeline/HscMain. - The GhcMonad overloading is gone from DriverPipeline and HscMain now. GhcMonad is now defined in a module of its own, and only used in the top-level GHC layer. DriverPipeline and HscMain use the plain IO monad and take HscEnv as an argument. - WarnLogMonad is gone. printExceptionAndWarnings is now called printException (the old name is deprecated). Session no longer contains warnings. - HscMain has its own little monad that collects warnings, and also plumbs HscEnv around. The idea here is that warnings are collected while we're in HscMain, but on exit from HscMain (any function) we check for warnings and either print them (via log_action, so IDEs can still override the printing), or turn them into an error if -Werror is on. - GhcApiCallbacks is gone, along with GHC.loadWithLogger. Thomas Schilling told me he wasn't using these, and I don't see a good reason to have them. - there's a new pure API to the parser (suggestion from Neil Mitchell): parser :: String -> DynFlags -> FilePath -> Either ErrorMessages (WarningMessages, Located (HsModule RdrName))
* Define setIdUnfoldingLazily, and use it in VectoriseIan Lynagh2010-10-191-1/+1
| | | | Fixes a loop in the compiler, when running the dph tests
* Implement INLINABLE pragma simonpj@microsoft.com2010-09-156-8/+8
| | | | Implements Trac #4299. Documentation to come.
* Fix build with 6.10Ian Lynagh2010-09-131-1/+4
|
* Remove two old junk filessimonpj@microsoft.com2010-09-131-651/+0
|
* Super-monster patch implementing the new typechecker -- at lastsimonpj@microsoft.com2010-09-137-3/+659
| | | | | | | | | This major patch implements the new OutsideIn constraint solving algorithm in the typecheker, following our JFP paper "Modular type inference with local assumptions". Done with major help from Dimitrios Vytiniotis and Brent Yorgey.
* Fix warningsIan Lynagh2010-09-093-3/+0
|
* Finish breaking up vectoriser utilsbenl@ouroborus.net2010-09-0917-388/+519
|
* Move VectType module to Vectorise treebenl@ouroborus.net2010-09-094-11/+6
|
* Sort all the PADict/PData/PRDict/PRepr stuff into their own modulesbenl@ouroborus.net2010-09-095-483/+545
|
* Break out Repr and PADict stuff for vectorisation of ADTs to their own modulesbenl@ouroborus.net2010-09-093-387/+440
|
* Break out conversion functions to own modulebenl@ouroborus.net2010-09-092-79/+90
|
* Comments and formatting onlybenl@ouroborus.net2010-09-091-26/+47
|
* Fix warnings on WindowsIan Lynagh2010-09-051-3/+0
|
* Break out hoisting utils into their own modulebenl@ouroborus.net2010-09-086-71/+97
|
* Break out closure utils into own modulebenl@ouroborus.net2010-09-084-107/+136
|
* Move VectVar module to Vectorise treebenl@ouroborus.net2010-09-082-2/+2
|
* Break out vectorisation of expressions into own modulebenl@ouroborus.net2010-09-082-415/+414
|
* Break out TyCon classifier into own modulebenl@ouroborus.net2010-09-082-77/+107
|
* Break out vectorisation of TyConDecls into own modulebenl@ouroborus.net2010-09-082-166/+164
|