
#14944: Compile speed regression -------------------------------------+------------------------------------- Reporter: br1 | Owner: dfeuer Type: bug | Status: new Priority: normal | Milestone: Component: Compiler | Version: 8.4.1 Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: Type of failure: Compile-time | Unknown/Multiple performance bug | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Wiki Page: | -------------------------------------+------------------------------------- Comment (by dfeuer): In 7.8, Main starts compiling like this (from -dshow-passes): {{{ Result size of Desugar (after optimization) = {terms: 3,973, types: 630,023, coercions: 196} *** Simplifier: Result size of Simplifier iteration=1 = {terms: 3,384, types: 628,452, coercions: 5} Result size of Simplifier iteration=2 = {terms: 3,386, types: 628,458, coercions: 5} Result size of Simplifier iteration=3 = {terms: 3,384, types: 628,456, coercions: 5} Result size of Simplifier = {terms: 3,384, types: 628,456, coercions: 5} *** Specialise: Result size of Specialise = {terms: 4,785, types: 865,456, coercions: 5} }}} In 7.10, on the other hand, it starts like this: {{{ Result size of Desugar (after optimization) = {terms: 3,973, types: 630,023, coercions: 196} *** Simplifier: Result size of Simplifier iteration=1 = {terms: 4,362, types: 630,802, coercions: 196} Result size of Simplifier = {terms: 4,362, types: 630,802, coercions: 196} *** Specialise: Result size of Specialise = {terms: 12,088, types: 2,092,764, coercions: 392} }}} So 7.8 immediately tossed a slew of coercions in the first simplifier iteration, and the simplification otherwise kept sizes pretty much the same. In 7.10, we only do one round of simplification, the coercion count doesn't go down, the term count goes up a bit, and then specialization goes wild. No, I don't know what any of this really means. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/14944#comment:16 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler