[commit: nofib] master: Adapt `nofib` code to Foldable-generalised Prelude (5c9562c)
git at git.haskell.org
git at git.haskell.org
Wed Sep 24 10:15:39 UTC 2014
Repository : ssh://git@git.haskell.org/nofib
On branch : master
Link : http://ghc.haskell.org/trac/ghc/changeset/5c9562cfb48431c73d81be613d594a345e7ef73c/nofib
>---------------------------------------------------------------
commit 5c9562cfb48431c73d81be613d594a345e7ef73c
Author: Herbert Valerio Riedel <hvr at gnu.org>
Date: Tue Sep 23 23:41:37 2014 +0200
Adapt `nofib` code to Foldable-generalised Prelude
>---------------------------------------------------------------
5c9562cfb48431c73d81be613d594a345e7ef73c
real/anna/AbstractVals2.hs | 8 ++++----
real/veritas/DerivedRules.hs | 1 +
shootout/spectral-norm/Main.hs | 3 ++-
3 files changed, 7 insertions(+), 5 deletions(-)
diff --git a/real/anna/AbstractVals2.hs b/real/anna/AbstractVals2.hs
index 811f214..c223d5f 100644
--- a/real/anna/AbstractVals2.hs
+++ b/real/anna/AbstractVals2.hs
@@ -466,9 +466,9 @@ avMaxAddPtR x ys
| x `avBelowMax0R` ys = ys
| otherwise = x:[y | y <- ys, not (y << x)]
-avMinR = foldr avMinAddPtR []
+avMinR = foldr avMinAddPtR [] :: [Route] -> [Route]
-avMaxR = foldr avMaxAddPtR []
+avMaxR = foldr avMaxAddPtR [] :: [Route] -> [Route]
-- ==========================================================--
@@ -489,9 +489,9 @@ avMaxAddPtrep x ys
| x `avBelowMax0rep` ys = ys
| otherwise = x:[y | y <- ys, not (y `avBelowEQrep` x)]
-avMinrep = foldr avMinAddPtrep []
+avMinrep = foldr avMinAddPtrep [] :: [Rep] -> [Rep]
-avMaxrep = foldr avMaxAddPtrep []
+avMaxrep = foldr avMaxAddPtrep [] :: [Rep] -> [Rep]
-- ==========================================================--
diff --git a/real/veritas/DerivedRules.hs b/real/veritas/DerivedRules.hs
index e4c299b..e07b27e 100644
--- a/real/veritas/DerivedRules.hs
+++ b/real/veritas/DerivedRules.hs
@@ -152,5 +152,6 @@ find_betas
do_beta_red _ (App (Binder Lambda dc tm1 _ _) tm2 _ _)
= subst_trm dc tm1 tm2
+rep_beta :: Thm -> [[Int]] -> Thm
rep_beta = foldl beta_rw
diff --git a/shootout/spectral-norm/Main.hs b/shootout/spectral-norm/Main.hs
index ed6c022..1fae229 100644
--- a/shootout/spectral-norm/Main.hs
+++ b/shootout/spectral-norm/Main.hs
@@ -20,7 +20,8 @@ import Foreign
import Text.Printf
import Control.Concurrent
import Control.Monad
-import GHC.Base
+import GHC.Base (Int(..), Double(..), (+#), (*#), (/##),
+ quotInt, uncheckedIShiftRA#, int2Double#)
import GHC.Conc
type Reals = Ptr Double
More information about the ghc-commits
mailing list