diff options
author | Simon Peyton Jones <simonpj@microsoft.com> | 2015-06-01 08:51:10 +0100 |
---|---|---|
committer | Simon Peyton Jones <simonpj@microsoft.com> | 2015-06-01 17:08:48 +0100 |
commit | 5eee6a1ffa6e1705a1517631ba599fdb4455b416 (patch) | |
tree | 6d84c1ddfabbd580f1537ac2fa6219242a2b8837 /compiler/basicTypes/IdInfo.hs | |
parent | 928f536cc5a7d333335795b658bb3072f1b5df18 (diff) | |
download | haskell-5eee6a1ffa6e1705a1517631ba599fdb4455b416.tar.gz |
Move seqExpr, seqIdInfo etc to CoreUtils
Refactoring only : it just brings some scattered "seq" code together
Diffstat (limited to 'compiler/basicTypes/IdInfo.hs')
-rw-r--r-- | compiler/basicTypes/IdInfo.hs | 38 |
1 files changed, 1 insertions, 37 deletions
diff --git a/compiler/basicTypes/IdInfo.hs b/compiler/basicTypes/IdInfo.hs index eb897896a9..e9fccbec23 100644 --- a/compiler/basicTypes/IdInfo.hs +++ b/compiler/basicTypes/IdInfo.hs @@ -15,7 +15,6 @@ module IdInfo ( -- * The IdInfo type IdInfo, -- Abstract vanillaIdInfo, noCafIdInfo, - seqIdInfo, megaSeqIdInfo, -- ** The OneShotInfo type OneShotInfo(..), @@ -56,7 +55,7 @@ module IdInfo ( SpecInfo(..), emptySpecInfo, isEmptySpecInfo, specInfoFreeVars, - specInfoRules, seqSpecInfo, setSpecInfoHead, + specInfoRules, setSpecInfoHead, specInfo, setSpecInfo, -- ** The CAFInfo type @@ -194,35 +193,6 @@ data IdInfo -- n <=> all calls have at least n arguments } --- | Just evaluate the 'IdInfo' to WHNF -seqIdInfo :: IdInfo -> () -seqIdInfo (IdInfo {}) = () - --- | Evaluate all the fields of the 'IdInfo' that are generally demanded by the --- compiler -megaSeqIdInfo :: IdInfo -> () -megaSeqIdInfo info - = seqSpecInfo (specInfo info) `seq` - --- Omitting this improves runtimes a little, presumably because --- some unfoldings are not calculated at all --- seqUnfolding (unfoldingInfo info) `seq` - - seqDemandInfo (demandInfo info) `seq` - seqStrictnessInfo (strictnessInfo info) `seq` - seqCaf (cafInfo info) `seq` - seqOneShot (oneShotInfo info) `seq` - seqOccInfo (occInfo info) - -seqOneShot :: OneShotInfo -> () -seqOneShot l = l `seq` () - -seqStrictnessInfo :: StrictSig -> () -seqStrictnessInfo ty = seqStrictSig ty - -seqDemandInfo :: Demand -> () -seqDemandInfo dmd = seqDemand dmd - -- Setters setSpecInfo :: IdInfo -> SpecInfo -> IdInfo @@ -400,9 +370,6 @@ setSpecInfoHead :: Name -> SpecInfo -> SpecInfo setSpecInfoHead fn (SpecInfo rules fvs) = SpecInfo (map (setRuleIdName fn) rules) fvs -seqSpecInfo :: SpecInfo -> () -seqSpecInfo (SpecInfo rules fvs) = seqRules rules `seq` seqVarSet fvs - {- ************************************************************************ * * @@ -434,9 +401,6 @@ mayHaveCafRefs :: CafInfo -> Bool mayHaveCafRefs MayHaveCafRefs = True mayHaveCafRefs _ = False -seqCaf :: CafInfo -> () -seqCaf c = c `seq` () - instance Outputable CafInfo where ppr = ppCafInfo |