summaryrefslogtreecommitdiff
path: root/compiler
diff options
context:
space:
mode:
authorandy@galois.com <unknown>2007-06-26 05:34:29 +0000
committerandy@galois.com <unknown>2007-06-26 05:34:29 +0000
commitbda0a4f655b2f9892d2778b0ab1b5d437c392226 (patch)
tree97ceb9d157ca9c383bd8747c670ca28cb4234351 /compiler
parenta8ef5634ef302acac8fb70fcdeddbdbdfe2a18d9 (diff)
downloadhaskell-bda0a4f655b2f9892d2778b0ab1b5d437c392226.tar.gz
Making -fhpc work with a stage1 build, via the compat 'package'.
Diffstat (limited to 'compiler')
-rw-r--r--compiler/deSugar/Coverage.lhs14
-rw-r--r--compiler/main/StaticFlags.hs7
2 files changed, 3 insertions, 18 deletions
diff --git a/compiler/deSugar/Coverage.lhs b/compiler/deSugar/Coverage.lhs
index 501ee817db..a9b1a528e4 100644
--- a/compiler/deSugar/Coverage.lhs
+++ b/compiler/deSugar/Coverage.lhs
@@ -38,10 +38,8 @@ import Compat.Directory ( createDirectoryIfMissing )
import System.Directory ( createDirectoryIfMissing )
#endif
-#if GHCI
import Trace.Hpc.Mix
import Trace.Hpc.Util
-#endif
import BreakArray
import Data.HashTable ( hashString )
@@ -63,7 +61,6 @@ addCoverageTicksToBinds
-> LHsBinds Id
-> IO (LHsBinds Id, HpcInfo, ModBreaks)
-#if GHCI
addCoverageTicksToBinds dflags mod mod_loc tyCons binds = do
let orig_file =
@@ -102,7 +99,8 @@ addCoverageTicksToBinds dflags mod mod_loc tyCons binds = do
when (length entries' /= tickBoxCount st) $ do
panic "the number of .mix entries are inconsistent"
let hashNo = mixHash orig_file modTime tabStop entries'
- mixCreate hpc_dir mod_name (Mix orig_file modTime (toHash hashNo) tabStop entries')
+ mixCreate hpc_dir mod_name
+ $ Mix orig_file modTime (toHash hashNo) tabStop entries'
return $ hashNo
else do
return $ 0
@@ -715,11 +713,3 @@ mixHash :: FilePath -> Integer -> Int -> [MixEntry] -> Int
mixHash file tm tabstop entries = fromIntegral $ hashString
(show $ Mix file tm 0 tabstop entries)
\end{code}
-
-
-\begin{code}
-#else
-addCoverageTicksToBinds dflags mod mod_loc tyCons binds =
- return (binds, noHpcInfo, emptyModBreaks)
-#endif
-\end{code} \ No newline at end of file
diff --git a/compiler/main/StaticFlags.hs b/compiler/main/StaticFlags.hs
index 67e8ab58e5..457626c80c 100644
--- a/compiler/main/StaticFlags.hs
+++ b/compiler/main/StaticFlags.hs
@@ -163,7 +163,6 @@ static_flags = [
--------- Haskell Program Coverage -----------------------------------
, ( "fhpc" , PassFlag addOpt )
- , ( "fhpc-tracer" , PassFlag addOpt )
--------- Profiling --------------------------------------------------
, ( "auto-all" , NoArg (addOpt "-fauto-sccs-on-all-toplevs") )
@@ -284,12 +283,8 @@ opt_AutoSccsOnIndividualCafs = lookUp FSLIT("-fauto-sccs-on-individual-cafs")
opt_SccProfilingOn = lookUp FSLIT("-fscc-profiling")
opt_DoTickyProfiling = WayTicky `elem` (unsafePerformIO $ readIORef v_Ways)
--- Hpc opts, only work in a stage2 build
-#if GHCI
+-- Hpc opts
opt_Hpc = lookUp FSLIT("-fhpc")
-#else
-opt_Hpc = False
-#endif
-- language opts
opt_DictsStrict = lookUp FSLIT("-fdicts-strict")