projects
/
ghc-hetmet.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
[project @ 2005-07-28 12:57:13 by simonmar]
[ghc-hetmet.git]
/
ghc
/
compiler
/
simplCore
/
SAT.lhs
diff --git
a/ghc/compiler/simplCore/SAT.lhs
b/ghc/compiler/simplCore/SAT.lhs
index
72c6709
..
81f3c4c
100644
(file)
--- a/
ghc/compiler/simplCore/SAT.lhs
+++ b/
ghc/compiler/simplCore/SAT.lhs
@@
-1,5
+1,5
@@
%
%
-% (c) The GRASP/AQUA Project, Glasgow University, 1992-1996
+% (c) The GRASP/AQUA Project, Glasgow University, 1992-1998
%
%************************************************************************
%* *
%
%************************************************************************
%* *
@@
-38,27
+38,31
@@
Experimental Evidence: Heap: +/- 7%
Instrs: Always improves for 2 or more Static Args.
\begin{code}
Instrs: Always improves for 2 or more Static Args.
\begin{code}
-#include "HsVersions.h"
-
module SAT ( doStaticArgs ) where
module SAT ( doStaticArgs ) where
-import Ubiq{-uitous-}
-import Util ( panic )
+#include "HsVersions.h"
+
+import Panic ( panic )
doStaticArgs = panic "SAT.doStaticArgs (ToDo)"
{- LATER: to end of file:
doStaticArgs = panic "SAT.doStaticArgs (ToDo)"
{- LATER: to end of file:
-import Maybes ( Maybe(..) )
import SATMonad
import Util
\end{code}
\begin{code}
import SATMonad
import Util
\end{code}
\begin{code}
-doStaticArgs :: [CoreBinding] -> UniqSupply -> [CoreBinding]
+doStaticArgs :: [CoreBind] -> UniqSupply -> [CoreBind]
doStaticArgs binds
doStaticArgs binds
- = initSAT (mapSAT sat_bind binds)
+ = do {
+ showPass "Static argument";
+ let { binds' = initSAT (mapSAT sat_bind binds) };
+ endPass "Static argument"
+ False -- No specific flag for dumping SAT
+ binds'
+ }
where
sat_bind (NonRec binder expr)
= emptyEnvSAT `thenSAT_`
where
sat_bind (NonRec binder expr)
= emptyEnvSAT `thenSAT_`
@@
-94,10
+98,6
@@
satExpr var@(Var v)
satExpr lit@(Lit _) = returnSAT lit
satExpr lit@(Lit _) = returnSAT lit
-satExpr e@(Con con types args)
- = mapSAT satAtom args `thenSAT_`
- returnSAT e
-
satExpr e@(Prim prim ty args)
= mapSAT satAtom args `thenSAT_`
returnSAT e
satExpr e@(Prim prim ty args)
= mapSAT satAtom args `thenSAT_`
returnSAT e
@@
-165,13
+165,9
@@
satExpr (Let (Rec binds) body)
mapSAT satExpr rhss `thenSAT` \ rhss' ->
returnSAT (Let (Rec (zipEqual "satExpr:Rec" binders rhss')) body')
mapSAT satExpr rhss `thenSAT` \ rhss' ->
returnSAT (Let (Rec (zipEqual "satExpr:Rec" binders rhss')) body')
-satExpr (SCC cc expr)
- = satExpr expr `thenSAT` \ expr2 ->
- returnSAT (SCC cc expr2)
-
-satExpr (Coerce c ty expr)
+satExpr (Note note expr)
= satExpr expr `thenSAT` \ expr2 ->
= satExpr expr `thenSAT` \ expr2 ->
- returnSAT (Coerce c ty expr2)
+ returnSAT (Note note expr2)
\end{code}
\begin{code}
\end{code}
\begin{code}