diff options
Diffstat (limited to 'compiler/simplCore')
-rw-r--r-- | compiler/simplCore/CSE.hs | 10 | ||||
-rw-r--r-- | compiler/simplCore/CallArity.hs | 2 | ||||
-rw-r--r-- | compiler/simplCore/CoreMonad.hs | 4 | ||||
-rw-r--r-- | compiler/simplCore/Exitify.hs | 2 | ||||
-rw-r--r-- | compiler/simplCore/FloatIn.hs | 12 | ||||
-rw-r--r-- | compiler/simplCore/FloatOut.hs | 2 | ||||
-rw-r--r-- | compiler/simplCore/OccurAnal.hs | 22 | ||||
-rw-r--r-- | compiler/simplCore/SetLevels.hs | 12 | ||||
-rw-r--r-- | compiler/simplCore/SimplCore.hs | 2 | ||||
-rw-r--r-- | compiler/simplCore/SimplMonad.hs | 2 | ||||
-rw-r--r-- | compiler/simplCore/SimplUtils.hs | 20 | ||||
-rw-r--r-- | compiler/simplCore/Simplify.hs | 36 |
12 files changed, 63 insertions, 63 deletions
diff --git a/compiler/simplCore/CSE.hs b/compiler/simplCore/CSE.hs index 96fbd07454..0758ce930a 100644 --- a/compiler/simplCore/CSE.hs +++ b/compiler/simplCore/CSE.hs @@ -84,7 +84,7 @@ Let-bindings have two cases, implemented by addBinding. - First, the original RHS might have been (g z) which has CSE'd with an enclosing (let y = g z in ...). This is super-important. - See Trac #5996: + See #5996: x1 = C a b x2 = C x1 b y1 = C a b @@ -104,7 +104,7 @@ Let-bindings have two cases, implemented by addBinding. Note that we use EXTEND even for a trivial expression, provided it is not a variable or literal. In particular this /includes/ type - applications. This can be important (Trac #13156); e.g. + applications. This can be important (#13156); e.g. case f @ Int of { r1 -> case f @ Int of { r2 -> ... Here we want to common-up the two uses of (f @ Int) so we can @@ -419,7 +419,7 @@ addBinding env in_id out_id rhs' -- Putting the Id into the cs_map makes it possible that -- it'll become shared more than it is now, which would -- invalidate (the usage part of) its demand info. - -- This caused Trac #100218. + -- This caused #100218. -- Easiest thing is to zap the usage info; subsequently -- performing late demand-analysis will restore it. Don't zap -- the strictness info; it's not necessary to do so, and losing @@ -475,11 +475,11 @@ The net effect is that for the y-binding we want to - Use SUBSTITUTE, by extending the substitution with y :-> x - but leave the original binding for y undisturbed -This is done by cse_bind. I got it wrong the first time (Trac #13367). +This is done by cse_bind. I got it wrong the first time (#13367). Note [Delay inlining after CSE] ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -Suppose (Trac #15445) we have +Suppose (#15445) we have f,g :: Num a => a -> a f x = ...f (x-1)..... g y = ...g (y-1) .... diff --git a/compiler/simplCore/CallArity.hs b/compiler/simplCore/CallArity.hs index ba1aa243ac..bd5b3a3055 100644 --- a/compiler/simplCore/CallArity.hs +++ b/compiler/simplCore/CallArity.hs @@ -418,7 +418,7 @@ like normal functions. This is ok. The analysis *could* make use of the fact that join points are always evaluated in the same context as the join-binding they are defined in and are always one-shot, and handle join points separately, as suggested in -https://ghc.haskell.org/trac/ghc/ticket/13479#comment:10. +https://gitlab.haskell.org/ghc/ghc/issues/13479#note_134870. This *might* be more efficient (for example, join points would not have to be considered interesting variables), but it would also add redundant code. So for now we do not do that. diff --git a/compiler/simplCore/CoreMonad.hs b/compiler/simplCore/CoreMonad.hs index 0c5d8d9fd2..4cdb231bd8 100644 --- a/compiler/simplCore/CoreMonad.hs +++ b/compiler/simplCore/CoreMonad.hs @@ -558,7 +558,7 @@ data CoreReader = CoreReader { -- Note: CoreWriter used to be defined with data, rather than newtype. If it -- is defined that way again, the cw_simpl_count field, at least, must be --- strict to avoid a space leak (Trac #7702). +-- strict to avoid a space leak (#7702). newtype CoreWriter = CoreWriter { cw_simpl_count :: SimplCount } @@ -589,7 +589,7 @@ instance Monad CoreM where let w = w1 `plusWriter` w2 return $ seq w (y, s'', w) -- forcing w before building the tuple avoids a space leak - -- (Trac #7702) + -- (#7702) instance Applicative CoreM where pure x = CoreM $ \s -> nop s x diff --git a/compiler/simplCore/Exitify.hs b/compiler/simplCore/Exitify.hs index 3e7d503d31..f5a4138566 100644 --- a/compiler/simplCore/Exitify.hs +++ b/compiler/simplCore/Exitify.hs @@ -245,7 +245,7 @@ exitifyRec in_scope pairs | otherwise = (fvs', acc) -- We are going to abstract over these variables, so we must - -- zap any IdInfo they have; see Trac #15005 + -- zap any IdInfo they have; see #15005 -- cf. SetLevels.abstractVars zap v | isId v = setIdInfo v vanillaIdInfo | otherwise = v diff --git a/compiler/simplCore/FloatIn.hs b/compiler/simplCore/FloatIn.hs index 07f05493eb..216e848889 100644 --- a/compiler/simplCore/FloatIn.hs +++ b/compiler/simplCore/FloatIn.hs @@ -210,7 +210,7 @@ only way that can happen is if the binding wrapped the literal /in the original input program/. e.g. case x of { DEFAULT -> 1# } But, while this may be unusual it is not actually wrong, and it did -once happen (Trac #15696). +once happen (#15696). Note [Do not destroy the let/app invariant] ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ @@ -307,7 +307,7 @@ be dropped right away. fiExpr dflags to_drop lam@(_, AnnLam _ _) | noFloatIntoLam bndrs -- Dump it all here - -- NB: Must line up with noFloatIntoRhs (AnnLam...); see Trac #7088 + -- NB: Must line up with noFloatIntoRhs (AnnLam...); see #7088 = wrapFloats to_drop (mkLams bndrs (fiExpr dflags [] body)) | otherwise -- Float inside @@ -391,7 +391,7 @@ fiExpr dflags to_drop (_,AnnLet bind body) {- Note [Floating primops] ~~~~~~~~~~~~~~~~~~~~~~~~~~ We try to float-in a case expression over an unlifted type. The -motivating example was Trac #5658: in particular, this change allows +motivating example was #5658: in particular, this change allows array indexing operations, which have a single DEFAULT alternative without any binders, to be floated inward. @@ -421,10 +421,10 @@ But there are wrinkles Solution: only float cases into the branches of other cases, and not into the arguments of an application, or the RHS of a let. This is somewhat conservative, but it's simple. And it still hits the - cases like Trac #5658. This is implemented in sepBindsByJoinPoint; + cases like #5658. This is implemented in sepBindsByJoinPoint; if is_case is False we dump all floating cases right here. -* Trac #14511 is another example of why we want to restrict float-in +* #14511 is another example of why we want to restrict float-in of case-expressions. Consider case indexArray# a n of (# r #) -> writeArray# ma i (f r) Now, floating that indexing operation into the (f r) thunk will @@ -613,7 +613,7 @@ would destroy the let/app invariant. (a) any non-one-shot value lambdas or (b) all type lambdas In both cases we'll float straight back out again - NB: Must line up with fiExpr (AnnLam...); see Trac #7088 + NB: Must line up with fiExpr (AnnLam...); see #7088 (a) is important: we /must/ float into a one-shot lambda group (which includes join points). This makes a big difference diff --git a/compiler/simplCore/FloatOut.hs b/compiler/simplCore/FloatOut.hs index 0aa48543de..1f1dd5c4ba 100644 --- a/compiler/simplCore/FloatOut.hs +++ b/compiler/simplCore/FloatOut.hs @@ -305,7 +305,7 @@ Nor is it a good idea to dump them in the rhs, but outside the lambda f = case x of I# y -> \xy. body because now f's arity might get worse, which is Not Good. (And if there's an SCC around the RHS it might not get better again. -See Trac #5342.) +See #5342.) So, gruesomely, we split the floats into * the outer FloatLets, which can join the Rec, and diff --git a/compiler/simplCore/OccurAnal.hs b/compiler/simplCore/OccurAnal.hs index c3414b1fdb..ecad4a585f 100644 --- a/compiler/simplCore/OccurAnal.hs +++ b/compiler/simplCore/OccurAnal.hs @@ -83,7 +83,7 @@ occurAnalysePgm this_mod active_unf active_rule imp_rules binds initial_uds -- It's crucial to re-analyse the glommed-together bindings -- so that we establish the right loop breakers. Otherwise - -- we can easily create an infinite loop (Trac #9583 is an example) + -- we can easily create an infinite loop (#9583 is an example) initial_uds = addManyOccsSet emptyDetails (rulesFreeVars imp_rules) @@ -124,7 +124,7 @@ occurAnalyseExpr' enable_binder_swap expr {- Note [Plugin rules] ~~~~~~~~~~~~~~~~~~~~~~ -Conal Elliott (Trac #11651) built a GHC plugin that added some +Conal Elliott (#11651) built a GHC plugin that added some BuiltinRules (for imported Ids) to the mg_rules field of ModGuts, to do some domain-specific transformations that could not be expressed with an ordinary pattern-matching CoreRule. But then we can't extract @@ -1020,7 +1020,7 @@ terminate in a constant number of iterations, rather than O(N) iterations. You might thing that it's very unlikely, but RULES make it much -more likely. Here's a real example from Trac #1969: +more likely. Here's a real example from #1969: Rec { $dm = \d.\x. op d {-# RULES forall d. $dm Int d = $s$dm1 forall d. $dm Bool d = $s$dm2 #-} @@ -1439,7 +1439,7 @@ Note [Loop breakers, node scoring, and stability] To choose a loop breaker, we give a NodeScore to each node in the SCC, and pick the one with the best score (according to 'betterLB'). -We need to be jolly careful (Trac #12425, #12234) about the stability +We need to be jolly careful (#12425, #12234) about the stability of this choice. Suppose we have let rec { f = ...g...g... @@ -1610,10 +1610,10 @@ Consider join j = Just x We want to inline x into j right away, so we don't want to give -the join point a RhsCtxt (Trac #14137). It's not a huge deal, because +the join point a RhsCtxt (#14137). It's not a huge deal, because the FloatIn pass knows to float into join point RHSs; and the simplifier does not float things out of join point RHSs. But it's a simple, cheap -thing to do. See Trac #14137. +thing to do. See #14137. Note [Cascading inlines] ~~~~~~~~~~~~~~~~~~~~~~~~ @@ -1932,7 +1932,7 @@ A': Non-obviously saturated applications: eg build (f (\x y -> expensive)) that sense, f is saturated, and we may proceed as described above. Hence the computation of 'guaranteed_val_args' in occAnalApp, using - '(occ_one_shots env)'. See also Trac #13227, comment:9 + '(occ_one_shots env)'. See also #13227, comment:9 B: Let-bindings: eg let f = \c. let ... in \n -> blah in (build f, build f) @@ -2322,7 +2322,7 @@ we will get Core Lint never expects to find an *occurrence* of an Id marked as Dead, so we must zap the OccInfo on cb before making the -binding x = cb. See Trac #5028. +binding x = cb. See #5028. NB: the OccInfo on /occurrences/ really doesn't matter much; the simplifier doesn't use it. So this is only to satisfy the perhpas-over-picky Lint. @@ -2409,7 +2409,7 @@ mkAltEnv env@(OccEnv { occ_gbl_scrut = pe }) scrut case_bndr , Just (localise v, rhs) ) -- ToDO: this isGlobalId stuff is a TEMPORARY FIX -- to avoid the binder-swap for GlobalIds - -- See Trac #16346 + -- See #16346 case_bndr' = Var (zapIdOccInfo case_bndr) -- See Note [Zap case binders in proxy bindings] @@ -2556,7 +2556,7 @@ It's obviously wrong to mark CoVars as dead if they are used. Currently we don't traverse types to gather usase info for CoVars, so we had better treat them as having noOccInfo. -This showed up in Trac #15696 we had something like +This showed up in #15696 we had something like case eq_sel d of co -> ...(typeError @(...co...) "urk")... Then 'd' was substitued by a dictionary, so the expression @@ -2828,7 +2828,7 @@ unfolding captured by the INLINE pragma has arity 1. If we try to convert g to be a join point, its unfolding will still have arity 1 (since it is stable, and we don't meddle with stable unfoldings), and Lint will complain (see Note [Invariants on join points], (2a), in -CoreSyn. Trac #13413. +CoreSyn. #13413. Moreover, since g is going to be inlined anyway, there is no benefit from making it a join point. diff --git a/compiler/simplCore/SetLevels.hs b/compiler/simplCore/SetLevels.hs index 2f993b7148..fef15a47b2 100644 --- a/compiler/simplCore/SetLevels.hs +++ b/compiler/simplCore/SetLevels.hs @@ -548,7 +548,7 @@ must be careful to test the *result* scrutinee ('x' in this case), not the *input* one 'y'. The latter *is* in HNF here (because y is evaluated), but the former is not -- and indeed we can't float the inner case out, at least not unless x is also evaluated at its binding -site. See Trac #5453. +site. See #5453. That's why we apply exprIsHNF to scrut' and not to scrut. @@ -755,7 +755,7 @@ I think this is obselete; the flag seems always on.] Note [Floating join point bindings] ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Mostly we only float a join point if it can /stay/ a join point. But -there is one exception: if it can go to the top level (Trac #13286). +there is one exception: if it can go to the top level (#13286). Consider f x = joinrec j y n = <...j y' n'...> in jump j x 0 @@ -808,7 +808,7 @@ and replace the original (f x) with case (case y of I# r -> r) of r -> blah Being able to float unboxed expressions is sometimes important; see -Trac #12603. I'm not sure how /often/ it is important, but it's +#12603. I'm not sure how /often/ it is important, but it's not hard to achieve. We only do it for a fixed collection of types for which we have a @@ -912,7 +912,7 @@ Id, *immediately*, for three reasons: errors, e.g. via a case with empty alternatives: (case x of {}) Lint complains unless the scrutinee of such a case is clearly bottom. - This was reported in Trac #11290. But since the whole bottoming-float + This was reported in #11290. But since the whole bottoming-float thing is based on the cheap-and-cheerful exprIsBottom, I'm not sure that it'll nail all such cases. @@ -1267,7 +1267,7 @@ Conclusion: use lvlMFE if there are * any value lambdas in the original function, and * this is not a bottoming function (the is_bot argument) Use lvlExpr otherwise. A little subtle, and I got it wrong at least twice -(e.g. Trac #13369). +(e.g. #13369). -} {- @@ -1398,7 +1398,7 @@ That's why we have this as_far_as_poss stuff. Usually as_far_as_poss is just tOP_LEVEL; but occasionally a coercion variable (which is an Id) mentioned in type prevents this. -Example Trac #14270 comment:15. +Example #14270 comment:15. -} diff --git a/compiler/simplCore/SimplCore.hs b/compiler/simplCore/SimplCore.hs index 168ece971c..7f2a0ea589 100644 --- a/compiler/simplCore/SimplCore.hs +++ b/compiler/simplCore/SimplCore.hs @@ -339,7 +339,7 @@ getCoreToDo dflags -- really really one-shot thunks. Only needed if the demand analyser -- has run at all. See Note [Final Demand Analyser run] in DmdAnal -- It is EXTREMELY IMPORTANT to run this pass, otherwise execution - -- can become /exponentially/ more expensive. See Trac #11731, #12996. + -- can become /exponentially/ more expensive. See #11731, #12996. runWhen (strictness || late_dmd_anal) CoreDoStrictness, maybe_rule_check (Phase 0) diff --git a/compiler/simplCore/SimplMonad.hs b/compiler/simplCore/SimplMonad.hs index 81654e9af2..17a3232957 100644 --- a/compiler/simplCore/SimplMonad.hs +++ b/compiler/simplCore/SimplMonad.hs @@ -97,7 +97,7 @@ computeMaxTicks dflags size -- MAGIC NUMBER, multiplies the simplTickFactor -- We can afford to be generous; this is really -- just checking for loops, and shouldn't usually fire - -- A figure of 20 was too small: see Trac #5539. + -- A figure of 20 was too small: see #5539. {-# INLINE thenSmpl #-} {-# INLINE thenSmpl_ #-} diff --git a/compiler/simplCore/SimplUtils.hs b/compiler/simplCore/SimplUtils.hs index 265b0fb5f9..f42a5d9756 100644 --- a/compiler/simplCore/SimplUtils.hs +++ b/compiler/simplCore/SimplUtils.hs @@ -542,7 +542,7 @@ on its first argument -- it must be saturated for these to kick in Note [Do not expose strictness if sm_inline=False] ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -Trac #15163 showed a case in which we had +#15163 showed a case in which we had {-# INLINE [1] zip #-} zip = undefined @@ -708,7 +708,7 @@ float, exposing the value, if we inline. That makes it different to exprIsHNF. Before 2009 we said it was interesting if the argument had *any* structure -at all; i.e. (hasSomeUnfolding v). But does too much inlining; see Trac #3016. +at all; i.e. (hasSomeUnfolding v). But does too much inlining; see #3016. But we don't regard (f x y) as interesting, unless f is unsaturated. If it's saturated and f hasn't inlined, then it's probably not going @@ -822,12 +822,12 @@ When simplifying a rule LHS, refrain from /any/ inlining or applying of other RULES. Doing anything to the LHS is plain confusing, because it means that what the -rule matches is not what the user wrote. c.f. Trac #10595, and #10528. +rule matches is not what the user wrote. c.f. #10595, and #10528. Moreover, inlining (or applying rules) on rule LHSs risks introducing -Ticks into the LHS, which makes matching trickier. Trac #10665, #10745. +Ticks into the LHS, which makes matching trickier. #10665, #10745. Doing this to either side confounds tools like HERMIT, which seek to reason -about and apply the RULES as originally written. See Trac #10829. +about and apply the RULES as originally written. See #10829. Note [No eta expansion in stable unfoldings] ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ @@ -844,7 +844,7 @@ we do not want to eta-expand to -- = (/\a \(d:Ord a) (x:a) (eta:State#). bla eta) |> co because not specialisation of the overloading doesn't work properly -(see Note [Specialisation shape] in Specialise), Trac #9509. +(see Note [Specialisation shape] in Specialise), #9509. So we disable eta-expansion in stable unfoldings. @@ -1109,7 +1109,7 @@ it might make fInt look big, and we'll lose the opportunity to inline f at each of fInt's call sites. The INLINE pragma will only inline when the application is saturated for exactly this reason; and we don't want PreInlineUnconditionally to second-guess it. A live example is -Trac #3736. +#3736. c.f. Note [Stable unfoldings and postInlineUnconditionally] NB: if the pragma is INLINEABLE, then we don't want to behave in @@ -1516,7 +1516,7 @@ tryEtaExpandRhs mode bndr rhs ; return (count isId join_bndrs, exprIsBottom join_body, rhs) } -- Note [Do not eta-expand join points] -- But do return the correct arity and bottom-ness, because - -- these are used to set the bndr's IdInfo (Trac #15517) + -- these are used to set the bndr's IdInfo (#15517) | otherwise = do { (new_arity, is_bot, new_rhs) <- try_expand @@ -1614,7 +1614,7 @@ Note [Do not eta-expand PAPs] ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ We used to have old_arity = manifestArity rhs, which meant that we would eta-expand even PAPs. But this gives no particular advantage, -and can lead to a massive blow-up in code size, exhibited by Trac #9020. +and can lead to a massive blow-up in code size, exhibited by #9020. Suppose we have a PAP foo :: IO () foo = returnIO () @@ -1731,7 +1731,7 @@ new binding is abstracted. Note that poly_t = /\ a b -> (e1, e2) poly_x = /\ a -> fst (poly_t a *b*) - * We must do closeOverKinds. Example (Trac #10934): + * We must do closeOverKinds. Example (#10934): f = /\k (f:k->*) (a:k). let t = AccFailure @ (f a) in ... Here we want to float 't', but we must remember to abstract over 'k' as well, even though it is not explicitly mentioned in the RHS, diff --git a/compiler/simplCore/Simplify.hs b/compiler/simplCore/Simplify.hs index 2156dc55b8..0130e06469 100644 --- a/compiler/simplCore/Simplify.hs +++ b/compiler/simplCore/Simplify.hs @@ -746,7 +746,7 @@ arity computation it performs (via CoreArity.findRhsArity) already does a simple bottoming-expression analysis. So all we need to do is propagate that info to the binder's IdInfo. -This showed up in Trac #12150; see comment:16. +This showed up in #12150; see comment:16. Note [Setting the demand info] ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ @@ -1218,7 +1218,7 @@ rebuild env expr cont {- Note [Optimising reflexivity] ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ It's important (for compiler performance) to get rid of reflexivity as soon -as it appears. See Trac #11735, #14737, and #15019. +as it appears. See #11735, #14737, and #15019. In particular, we want to behave well on @@ -1232,7 +1232,7 @@ In particular, we want to behave well on build up NthCo stacks. Silly to do that if co is reflexive. However, we don't want to call isReflexiveCo too much, because it uses -type equality which is expensive on big types (Trac #14737 comment:7). +type equality which is expensive on big types (#14737 comment:7). A good compromise (determined experimentally) seems to be to call isReflexiveCo @@ -1240,7 +1240,7 @@ isReflexiveCo * at the end In investigating this I saw missed opportunities for on-the-fly -coercion shrinkage. See Trac #15090. +coercion shrinkage. See #15090. -} @@ -1292,7 +1292,7 @@ simplCast env body co0 cont0 -- 'co' with the InExpr 'arg', so we simplify -- to make it all consistent. It's a bit messy. -- But it isn't a common case. - -- Example of use: Trac #995 + -- Example of use: #995 ; return (ApplyToVal { sc_arg = mkCast arg' co1 , sc_env = arg_se' , sc_dup = dup' @@ -1524,7 +1524,7 @@ Simplifying rules and stable-unfoldings happens a bit after simplifying the right-hand side, so we remember whether or not it is a join point, and what 'cont' is, in a value of type MaybeJoinCont -Trac #13900 wsa caused by forgetting to push 'cont' into the RHS +#13900 wsa caused by forgetting to push 'cont' into the RHS of a SpecConstr-generated RULE for a join point. -} @@ -2269,7 +2269,7 @@ where 'r' is used strictly in (..r..), we can safely transform to This is a Good Thing, because 'r' might be dead (if the body just calls error), or might be used just once (in which case it can be inlined); or we might be able to float the let-binding up or down. -E.g. Trac #15631 has an example. +E.g. #15631 has an example. Note that this can change the error behaviour. For example, we might transform @@ -2280,7 +2280,7 @@ let-bound to (error "good"). Nevertheless, the paper "A semantics for imprecise exceptions" allows this transformation. If you want to fix the evaluation order, use -'pseq'. See Trac #8900 for an example where the loss of this +'pseq'. See #8900 for an example where the loss of this transformation bit us in practice. See also Note [Empty case alternatives] in CoreSyn. @@ -2298,7 +2298,7 @@ There have been various earlier versions of this patch: scrut_is_demanded_var _ = False This only fired if the scrutinee was a /variable/, which seems - an unnecessary restriction. So in Trac #15631 I relaxed it to allow + an unnecessary restriction. So in #15631 I relaxed it to allow arbitrary scrutinees. Less code, less to explain -- but the change had 0.00% effect on nofib. @@ -2313,7 +2313,7 @@ There have been various earlier versions of this patch: case_bndr_evald_next (Case e _ _ _) = case_bndr_evald_next e case_bndr_evald_next _ = False - This patch was part of fixing Trac #7542. See also + This patch was part of fixing #7542. See also Note [Eta reduction of an eval'd function] in CoreUtils.) @@ -2562,7 +2562,7 @@ We'd like to transform so that 'rhs' can take advantage of the form of x'. Notice that Note [Case of cast] (in OccurAnal) may then apply to the result. -We'd also like to eliminate empty types (Trac #13468). So if +We'd also like to eliminate empty types (#13468). So if data Void type instance F Bool = Void @@ -2698,7 +2698,7 @@ NB: simplLamBinders preserves this eval info In addition to handling data constructor fields with !s, addEvals also records the fact that the result of seq# is always in WHNF. -See Note [seq# magic] in PrelRules. Example (Trac #15226): +See Note [seq# magic] in PrelRules. Example (#15226): case seq# v s of (# s', v' #) -> E @@ -2707,7 +2707,7 @@ we want the compiler to be aware that v' is in WHNF in E. Open problem: we don't record that v itself is in WHNF (and we can't do it here). The right thing is to do some kind of binder-swap; -see Trac #15226 for discussion. +see #15226 for discussion. -} addEvals :: Maybe OutExpr -> DataCon -> [Id] -> [Id] @@ -2799,7 +2799,7 @@ The let/app invariant requires that y is evaluated in the call to reallyUnsafePtrEq#, which it is. But we still want that to be true if we propagate binders to occurrences. -This showed up in Trac #13027. +This showed up in #13027. Note [Add unfolding for scrutinee] ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ @@ -2975,7 +2975,7 @@ When we have of alts then we can just duplicate those alts because the A and C cases will disappear immediately. This is more direct than creating -join points and inlining them away. See Trac #4930. +join points and inlining them away. See #4930. -} -------------------- @@ -3208,7 +3208,7 @@ Supposing that body is big, we end up with This is just what we want because the rn produces a box that the case rn cancels with. -See Trac #4957 a fuller example. +See #4957 a fuller example. Note [Case binders and join points] ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ @@ -3306,7 +3306,7 @@ them. Thus: Now if the thing in the hole is a case expression (which is when we'll call mkDupableCont), we'll push the function call into the branches, which is what we want. Now RULES for f may fire, and -call-pattern specialisation. Here's an example from Trac #3116 +call-pattern specialisation. Here's an example from #3116 go (n+1) (case l of 1 -> bs' _ -> Chunk p fpc (o+1) (l-1) bs') @@ -3489,7 +3489,7 @@ simplStableUnfolding env top_lvl mb_cont id unf rhs_ty -- has got small. This happens, notably in the inlinings -- for dfuns for single-method classes; see -- Note [Single-method classes] in TcInstDcls. - -- A test case is Trac #4138 + -- A test case is #4138 -- But retain a previous boring_ok of True; e.g. see -- the way it is set in calcUnfoldingGuidanceWithArity in return (mkCoreUnfolding src is_top_lvl expr' guide') |