[GHC] #11068: Make Generic/Generic1 methods inlinable

GHC ghc-devs at haskell.org
Sat Nov 7 20:34:08 UTC 2015


#11068: Make Generic/Generic1 methods inlinable
-------------------------------------+-------------------------------------
        Reporter:  glguy             |                Owner:
            Type:  bug               |               Status:  new
        Priority:  normal            |            Milestone:
       Component:  Compiler          |              Version:  7.10.2
      Resolution:                    |             Keywords:
Operating System:  Unknown/Multiple  |         Architecture:
                                     |  Unknown/Multiple
 Type of failure:  None/Unknown      |            Test Case:
      Blocked By:                    |             Blocking:
 Related Tickets:                    |  Differential Rev(s):  Phab:D1447
       Wiki Page:                    |
-------------------------------------+-------------------------------------

Comment (by osa1):

 I remember chatting with some people at ICFP about optimizing Generics
 code.
 The problem was that sometimes GHC is able to optimize Generics-based code
 so
 that it doesn't use Generics methods anymore. For example, using Generics-
 based
 default method of `NFData` sometimes works well, generated code is same as
 hand-written code. But in some cases it never optimizes enough to
 eliminate
 Generics methods. For example, in my tests I was never able to eliminate
 Generics methods in Generics-based default implementation of `Binary`. I'm
 wondering if after this patch GHC is able to optimize such instances.
 @glguy
 have you tried anything like this?

 Looks like a good improvement to me, +1.

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


More information about the ghc-tickets mailing list