[GHC] #9546: filterM is not a good consumer for list fusion
#9546: filterM is not a good consumer for list fusion -------------------------------------+------------------------------------- Reporter: dfeuer | Owner: Type: bug | Status: new Priority: normal | Milestone: Component: Compiler | Version: 7.9 Keywords: | Operating System: Architecture: Unknown/Multiple | Unknown/Multiple Difficulty: Unknown | Type of failure: Runtime Blocked By: | performance bug Related Tickets: | Test Case: | Blocking: | Differential Revisions: -------------------------------------+------------------------------------- This one shouldn't cause any wonkiness; it just updates `filterM` to fuse is much the same way `mapM` does. -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/9546> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
#9546: filterM is not a good consumer for list fusion -------------------------------------+------------------------------------- Reporter: dfeuer | Owner: Type: bug | Status: patch Priority: normal | Milestone: Component: Compiler | Version: 7.9 Resolution: | Keywords: Operating System: | Architecture: Unknown/Multiple Unknown/Multiple | Difficulty: Unknown Type of failure: Runtime | Blocked By: performance bug | Related Tickets: Test Case: | Blocking: | Differential Revisions: | -------------------------------------+------------------------------------- Changes (by dfeuer): * status: new => patch -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/9546#comment:1> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
#9546: filterM is not a good consumer for list fusion -------------------------------------+------------------------------------- Reporter: dfeuer | Owner: Type: bug | Status: patch Priority: normal | Milestone: Component: Compiler | Version: 7.9 Resolution: | Keywords: Operating System: | Architecture: Unknown/Multiple Unknown/Multiple | Difficulty: Unknown Type of failure: Runtime | Blocked By: performance bug | Related Tickets: Test Case: | Blocking: | Differential Revisions: | -------------------------------------+------------------------------------- Comment (by nomeata): LGTM. (I’m a bit doubtful about `INLINE`ing such a rather large function, but `mapM` and `sequence` are also `INLINE`, so if it is ok for them, I guess it ought to be ok for this). -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/9546#comment:2> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
#9546: filterM is not a good consumer for list fusion -------------------------------------+------------------------------------- Reporter: dfeuer | Owner: Type: bug | Status: patch Priority: normal | Milestone: Component: Compiler | Version: 7.9 Resolution: | Keywords: Operating System: | Architecture: Unknown/Multiple Unknown/Multiple | Difficulty: Unknown Type of failure: Runtime | Blocked By: performance bug | Related Tickets: Test Case: | Blocking: | Differential Revisions: | -------------------------------------+------------------------------------- Comment (by dfeuer): Replying to [comment:2 nomeata]:
LGTM. (I’m a bit doubtful about `INLINE`ing such a rather large function, but `mapM` and `sequence` are also `INLINE`, so if it is ok for them, I guess it ought to be ok for this).
Would you be happier if it did a dance with `RULES`? -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/9546#comment:3> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
#9546: filterM is not a good consumer for list fusion -------------------------------------+------------------------------------- Reporter: dfeuer | Owner: Type: bug | Status: patch Priority: normal | Milestone: Component: Compiler | Version: 7.9 Resolution: | Keywords: Operating System: | Architecture: Unknown/Multiple Unknown/Multiple | Difficulty: Unknown Type of failure: Runtime | Blocked By: performance bug | Related Tickets: Test Case: | Blocking: | Differential Revisions: | -------------------------------------+------------------------------------- Comment (by nomeata): I’d be happier if we had numbers (time, allocation, binary size). Have you started to play around with the list-fusion-lab framework? -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/9546#comment:4> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
#9546: filterM is not a good consumer for list fusion -------------------------------------+------------------------------------- Reporter: dfeuer | Owner: Type: bug | Status: patch Priority: normal | Milestone: Component: Compiler | Version: 7.9 Resolution: | Keywords: Operating System: | Architecture: Unknown/Multiple Unknown/Multiple | Difficulty: Unknown Type of failure: Runtime | Blocked By: performance bug | Related Tickets: Test Case: | Blocking: | Differential Revisions: | -------------------------------------+------------------------------------- Comment (by dfeuer): Replying to [comment:4 nomeata]:
I’d be happier if we had numbers (time, allocation, binary size). Have you started to play around with the list-fusion-lab framework?
No, not yet. Unfortunately, finding actual uses to benchmark against is not so easy. Also unfortunately, GHC does not currently build for me. -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/9546#comment:5> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
#9546: filterM is not a good consumer for list fusion -------------------------------------+------------------------------------- Reporter: dfeuer | Owner: Type: bug | Status: patch Priority: normal | Milestone: Component: Compiler | Version: 7.9 Resolution: | Keywords: Operating System: | Architecture: Unknown/Multiple Unknown/Multiple | Difficulty: Unknown Type of failure: Runtime | Blocked By: performance bug | Related Tickets: Test Case: | Blocking: | Differential Revisions: | -------------------------------------+------------------------------------- Comment (by Joachim Breitner <mail@…>): In [changeset:"96a4062a7e7587592829c045b3b12c755cc8e329/ghc"]: {{{ #!CommitTicketReference repository="ghc" revision="96a4062a7e7587592829c045b3b12c755cc8e329" Make filterM a good consumer analogously to mapM. Fixes #9546. }}} -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/9546#comment:6> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
#9546: filterM is not a good consumer for list fusion -------------------------------------+------------------------------------- Reporter: dfeuer | Owner: Type: bug | Status: closed Priority: normal | Milestone: Component: Compiler | Version: 7.9 Resolution: fixed | Keywords: Operating System: | Architecture: Unknown/Multiple Unknown/Multiple | Difficulty: Unknown Type of failure: Runtime | Blocked By: performance bug | Related Tickets: Test Case: | Blocking: | Differential Revisions: | -------------------------------------+------------------------------------- Changes (by nomeata): * status: patch => closed * resolution: => fixed -- Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/9546#comment:7> GHC <http://www.haskell.org/ghc/> The Glasgow Haskell Compiler
participants (1)
-
GHC