X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=ghc%2Fcompiler%2FsimplCore%2FLiberateCase.lhs;h=bb9a08f1384f329e742e1fb09656dabbc86f4a8a;hb=3f2df52d6121fe36a05156b755f2a95c2ccea812;hp=a1bbe934e9610ea10335472eb316b5d722d789af;hpb=438596897ebbe25a07e1c82085cfbc5bdb00f09e;p=ghc-hetmet.git diff --git a/ghc/compiler/simplCore/LiberateCase.lhs b/ghc/compiler/simplCore/LiberateCase.lhs index a1bbe93..bb9a08f 100644 --- a/ghc/compiler/simplCore/LiberateCase.lhs +++ b/ghc/compiler/simplCore/LiberateCase.lhs @@ -11,7 +11,7 @@ module LiberateCase ( liberateCase ) where import CmdLineOpts ( opt_D_verbose_core2core, opt_LiberateCaseThreshold ) import CoreLint ( beginPass, endPass ) import CoreSyn -import CoreUnfold ( calcUnfoldingGuidance, UnfoldingGuidance(..) ) +import CoreUnfold ( calcUnfoldingGuidance, couldBeSmallEnoughToInline ) import Var ( Id ) import VarEnv import Maybes @@ -209,9 +209,7 @@ libCaseBind env (Rec pairs) -- [May 98: all this is now handled by SimplCore.tidyCore] rhs_small_enough rhs - = case (calcUnfoldingGuidance lIBERATE_BOMB_SIZE rhs) of - UnfoldNever -> False - _ -> True -- we didn't BOMB, so it must be OK + = couldBeSmallEnoughToInline (calcUnfoldingGuidance lIBERATE_BOMB_SIZE rhs) lIBERATE_BOMB_SIZE = bombOutSize env \end{code}