diff options
author | Ian Lynagh <igloo@earth.li> | 2008-12-18 16:19:28 +0000 |
---|---|---|
committer | Ian Lynagh <igloo@earth.li> | 2008-12-18 16:19:28 +0000 |
commit | fd12b167cd246087858d50ab66840274ef609f79 (patch) | |
tree | 8558630ebdc5d2a1d35c1c9f2cefa324639d8f5b /compiler/codeGen/StgCmmTicky.hs | |
parent | 840295515da399bd63d1ad789cda97007c96e93b (diff) | |
download | haskell-fd12b167cd246087858d50ab66840274ef609f79.tar.gz |
Use DynFlags to work out if we are doing ticky ticky profiling
We used to use StaticFlags
Diffstat (limited to 'compiler/codeGen/StgCmmTicky.hs')
-rw-r--r-- | compiler/codeGen/StgCmmTicky.hs | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/compiler/codeGen/StgCmmTicky.hs b/compiler/codeGen/StgCmmTicky.hs index 544f863012..2e4b29e73b 100644 --- a/compiler/codeGen/StgCmmTicky.hs +++ b/compiler/codeGen/StgCmmTicky.hs @@ -56,12 +56,13 @@ import CLabel import Module import Name import Id -import StaticFlags import BasicTypes import FastString import Constants import Outputable +import DynFlags + -- Turgid imports for showTypeCategory import PrelNames import TcType @@ -321,9 +322,9 @@ tickyAllocHeap hp -- Ticky utils ifTicky :: FCode () -> FCode () -ifTicky code - | opt_DoTickyProfiling = code - | otherwise = nopC +ifTicky code = do dflags <- getDynFlags + if doingTickyProfiling dflags then code + else nopC -- All the ticky-ticky counters are declared "unsigned long" in C bumpTickyCounter :: LitString -> FCode () |