
#9326: Minor change to list comprehension structure leads to poor performance -------------------------------------+------------------------------------- Reporter: dfeuer | Owner: Type: bug | Status: new Priority: normal | Milestone: Component: Compiler | Version: 7.8.3 Keywords: | Differential Revisions: Operating System: Unknown/Multiple | Architecture: Type of failure: Runtime | Unknown/Multiple performance bug | Difficulty: Unknown Test Case: | Blocked By: Blocking: | Related Tickets: -------------------------------------+------------------------------------- According to [http://stackoverflow.com/questions/24690406/haskell-list- comprehension-speed-inconsistencies] ''and my own testing'', the code in compspeed.hs reliably runs several times faster than the code in compspeedslow.hs with ghc 7.8.3, although this apparently does not happen with 7.6.3. The basic distinction is between a list comprehension of the form {{{ [(a,h) | ..., let h = expr] }}} and {{{ [(a,expr) | ...] }}} The core produced by -ddump-simpl is completely different in each case, so I can't figure out what's going on. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/9326 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler