#5642: Deriving Generic of a big type takes a long time and lots of space
---------------------------------+------------------------------------------
    Reporter:  basvandijk        |       Owner:  dimitris                    
        Type:  bug               |      Status:  new                         
    Priority:  normal            |   Component:  Compiler                    
     Version:  7.3               |    Keywords:                              
    Testcase:                    |   Blockedby:                              
          Os:  Unknown/Multiple  |    Blocking:                              
Architecture:  Unknown/Multiple  |     Failure:  Compile-time performance bug
---------------------------------+------------------------------------------
Changes (by dreixel):

  * owner:  dreixel => dimitris
  * version:  7.2.1 => 7.3


Comment:

 I thought the problem was the generation of Generic instances, but it
 isn't. If you write the instance by hand, it still takes long. So the
 bottleneck is the performance of the simplifier. Things have improved with
 the new coercion solver; see the following figures for compiling `derive
 Generic` on a datatype with 100/200/300 constructors:
 {{{
 ghc-7.2.1
 100     0m30.079s
 200     3m44.419s
 300     12m52.306s

 HEAD
 100     0m8.302s
 200     1m1.631s
 300     3m32.507s
 }}}

 But they could probably be much better, since the coercions introduced are
 not that complicated. I've notified Dimitrios, he'll look further into it.

-- 
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/5642#comment:6>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler

_______________________________________________
Glasgow-haskell-bugs mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs

Reply via email to