[GHC] #11292: Generics unboxed types: TEST=GEq1 WAY=optasm is failing

GHC ghc-devs at haskell.org
Thu Dec 31 23:27:45 UTC 2015


#11292: Generics unboxed types: TEST=GEq1 WAY=optasm is failing
-------------------------------------+-------------------------------------
        Reporter:  thomie            |                Owner:
            Type:  bug               |               Status:  closed
        Priority:  normal            |            Milestone:
       Component:  Compiler          |              Version:  7.11
      Resolution:  fixed             |             Keywords:
Operating System:  Unknown/Multiple  |         Architecture:
                                     |  Unknown/Multiple
 Type of failure:  None/Unknown      |            Test Case:
      Blocked By:                    |             Blocking:
 Related Tickets:  #11312            |  Differential Rev(s):  Phab:D1714
       Wiki Page:                    |
-------------------------------------+-------------------------------------

Comment (by simonpj):

 > I'm inclined to agree, but if we do fix this, we'd probably need to
 change the way `Addr#` is dealt with in datatypes as well for the sake of
 consistency.

 No... an `Addr#` might be returned from C-land by `malloc`, and might be
 perfectly stable.  It's just that primitive strings should not be compared
 with `eqAddr#`.  The bug is that primitive strings have type `Addr#`; they
 should have type `String#`.  And to compare `String#` you should use
 `strcmp`.  I suppose that means a new primitive type and family of
 operations over it... but that looks to me like the Right Thing to do.

 This NOINLINE stuff looks desperately fragile.... a bug waiting to happen.

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


More information about the ghc-tickets mailing list