Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
GHC
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Alexis King
GHC
Commits
dc388b4f
Commit
dc388b4f
authored
11 years ago
by
Joachim Breitner
Committed by
Joachim Breitner
11 years ago
Browse files
Options
Downloads
Patches
Plain Diff
More tracing in the demand analyser
parent
161d0cea
Loading
Loading
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
compiler/stranal/DmdAnal.lhs
+14
-2
14 additions, 2 deletions
compiler/stranal/DmdAnal.lhs
with
14 additions
and
2 deletions
compiler/stranal/DmdAnal.lhs
+
14
−
2
View file @
dc388b4f
...
...
@@ -188,8 +188,14 @@ dmdAnal env dmd (Lam var body)
env' = extendSigsWithLam env var
(body_ty, body') = dmdAnal env' body_dmd body
(lam_ty, var') = annotateLamIdBndr env notArgOfDfun body_ty one_shot var
lam_ty' = postProcessUnsat defer_and_use lam_ty
in
(postProcessUnsat defer_and_use lam_ty, Lam var' body')
-- pprTrace "dmdAnal:Lam" (vcat [ text "dmd" <+> ppr dmd
-- , text "body_ty" <+> ppr body_ty
-- , text "lam_ty" <+> ppr lam_ty
-- , text "lam_ty'" <+> ppr lam_ty'
-- ]) $
(lam_ty', Lam var' body')
dmdAnal env dmd (Case scrut case_bndr ty [alt@(DataAlt dc, bndrs, _)])
-- Only one alternative with a product constructor, and a complex scrutinee
...
...
@@ -337,6 +343,9 @@ dmdAnal env dmd (Let (Rec pairs) body)
body_ty1 = deleteFVs body_ty (map fst pairs)
body_ty2 = addLazyFVs body_ty1 lazy_fv
in
-- pprTrace "dmdAnal:LetRec" (vcat [ text "body_ty" <+> ppr body_ty
-- , text "body_ty1" <+> ppr body_ty1
-- , text "body_ty2" <+> ppr body_ty2]) $
body_ty2 `seq`
(body_ty2, Let (Rec pairs') body')
...
...
@@ -389,7 +398,10 @@ dmdAnalAlt env dmd (con,bndrs,rhs)
io_hack_reqd = con == DataAlt unboxedPairDataCon &&
idType (head bndrs) `eqType` realWorldStatePrimTy
in
in
-- pprTrace "dmdAnalAlt" (vcat [ text "rhs_ty" <+> ppr rhs_ty
-- , text "alt_ty" <+> ppr alt_ty
-- ]) $
(final_alt_ty, (con, bndrs', rhs'))
\end{code}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment