X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=ghc%2Fcompiler%2Fstranal%2FWorkWrap.lhs;fp=ghc%2Fcompiler%2Fstranal%2FWorkWrap.lhs;h=279a5f1f253f4fc1ee45af71a10a49cd40843373;hb=e0d750bedbd33f7a133c8c82c35fd8db537ab649;hp=331b62369afa2b36a96beca8c82624c36326c0f9;hpb=5cd3527da623a25b9ace2995f9d2e7f6c90c611f;p=ghc-hetmet.git diff --git a/ghc/compiler/stranal/WorkWrap.lhs b/ghc/compiler/stranal/WorkWrap.lhs index 331b623..279a5f1 100644 --- a/ghc/compiler/stranal/WorkWrap.lhs +++ b/ghc/compiler/stranal/WorkWrap.lhs @@ -16,12 +16,12 @@ import Id ( Id, idType, idNewStrictness, idArity, isOneShotLambda, setIdNewStrictness, zapIdNewStrictness, idInlinePragma, mkWorkerId, setIdWorkerInfo, setInlinePragma ) import Type ( Type ) -import IdInfo ( InlinePragInfo(..), isNeverInlinePrag, WorkerInfo(..) ) +import IdInfo ( WorkerInfo(..) ) import NewDemand ( Demand(..), StrictSig(..), DmdType(..), DmdResult(..), mkTopDmdType, isBotRes, returnsCPR ) import UniqSupply ( UniqSupply, initUs_, returnUs, thenUs, mapUs, getUniqueUs, UniqSM ) -import BasicTypes ( RecFlag(..), isNonRec ) +import BasicTypes ( RecFlag(..), isNonRec, Activation(..), isNeverActive ) import CmdLineOpts import WwLib import Outputable @@ -182,7 +182,7 @@ tryWW :: RecFlag -- if two, then a worker and a -- wrapper. tryWW is_rec fn_id rhs - | isNeverInlinePrag inline_prag + | isNeverActive inline_prag -- Don't split NOINLINE things, because they will never be inlined -- Furthermore, zap the strictess info in the Id. Why? Because -- the NOINLINE says "don't expose any of the inner workings at the call @@ -237,8 +237,8 @@ tryWW is_rec fn_id rhs wrap_rhs = wrap_fn work_id wrap_id = fn_id `setIdWorkerInfo` HasWorker work_id arity - `setInlinePragma` NoInlinePragInfo -- Zap any inline pragma; - -- Put it on the worker instead + `setInlinePragma` AlwaysActive -- Zap any inline pragma; + -- Put it on the worker instead in returnUs ([(work_id, work_rhs), (wrap_id, wrap_rhs)]) -- Worker first, because wrapper mentions it