[GHC] #15811: Comment out CONSTANT_FOLDED annotation for some GHC.Natural functions

GHC ghc-devs at haskell.org
Fri Oct 26 15:13:04 UTC 2018


#15811: Comment out CONSTANT_FOLDED annotation for some GHC.Natural functions
-------------------------------------+-------------------------------------
        Reporter:  darchon           |                Owner:  (none)
            Type:  feature request   |               Status:  patch
        Priority:  normal            |            Milestone:  8.6.2
       Component:  Compiler          |              Version:  8.6.1
      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:D5267
       Wiki Page:                    |
-------------------------------------+-------------------------------------
Changes (by darchon):

 * status:  new => patch


Old description:

> Some functions in GHC.Natural with a CONSTANT_FOLDED annotation don't
> have actual builtin rules (nor a builtin name in PrelNames and friends).
>
> This is hurting the Clash compiler because the workers for these
> functions do not end up in the .hi interface files, nor can we reliably
> define primops; meaning Clash cannot translate functions over Natural.
> This is doubly problematic because Natural is the underlying
> representation for KnownNat which Clash uses extensively.
>
> This feature request is simply a backstop for GHC 8.6.2 until proper
> builtin rules have been defined for the functions over the relevant
> Natural functions.

New description:

 Some functions in GHC.Natural with a CONSTANT_FOLDED annotation don't have
 actual builtin rules (nor a builtin name in PrelNames and friends).

 This is hurting the Clash compiler because the workers for these functions
 do not end up in the .hi interface files, nor can we reliably define
 primops; meaning Clash cannot translate functions over Natural. This is
 doubly problematic because Natural is the underlying representation for
 KnownNat which Clash uses extensively.

 This feature request is simply a backstop for GHC 8.6.2 until proper
 builtin rules are defined for the referred to functions in GHC.Natural

--

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


More information about the ghc-tickets mailing list