summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJoachim Breitner <mail@joachim-breitner.de>2017-07-31 22:56:51 -0400
committerJoachim Breitner <mail@joachim-breitner.de>2017-08-01 09:09:33 -0400
commitb311096c5cf4b669dcfceb99561ac6e1c4cca0cd (patch)
tree2049f756c47f54248b0795139711587c83737b4b
parent74c70166dc70486f3535d3c9d12071ea8a447389 (diff)
downloadhaskell-b311096c5cf4b669dcfceb99561ac6e1c4cca0cd.tar.gz
Simplify OccurAnal.tagRecBinders
No need to mark the binders with markNonTailCalled, as they already have been marked as such in rhs_udss' via adjust. Differential Revision: https://phabricator.haskell.org/D3810
-rw-r--r--compiler/simplCore/OccurAnal.hs9
1 files changed, 3 insertions, 6 deletions
diff --git a/compiler/simplCore/OccurAnal.hs b/compiler/simplCore/OccurAnal.hs
index 5dd30aa668..dbe1c48828 100644
--- a/compiler/simplCore/OccurAnal.hs
+++ b/compiler/simplCore/OccurAnal.hs
@@ -2657,12 +2657,9 @@ tagRecBinders lvl body_uds triples
-- 3. Compute final usage details from adjusted RHS details
adj_uds = body_uds +++ combineUsageDetailsList rhs_udss'
- -- 4. Tag each binder with its adjusted details modulo the
- -- join-point-hood decision
- occs = map (lookupDetails adj_uds) bndrs
- occs' | will_be_joins = occs
- | otherwise = map markNonTailCalled occs
- bndrs' = zipWith setBinderOcc occs' bndrs
+ -- 4. Tag each binder with its adjusted details
+ bndrs' = [ setBinderOcc (lookupDetails adj_uds bndr) bndr
+ | bndr <- bndrs ]
-- 5. Drop the binders from the adjusted details and return
usage' = adj_uds `delDetailsList` bndrs