[GHC] #8182: Parser.y.pp needs special treatment with -fcmm-sink

GHC ghc-devs at haskell.org
Wed Sep 4 18:58:28 CEST 2013


#8182: Parser.y.pp needs special treatment with -fcmm-sink
-------------------------------------+------------------------------------
        Reporter:  thoughtpolice     |            Owner:  thoughtpolice
            Type:  bug               |           Status:  new
        Priority:  highest           |        Milestone:  7.8.1
       Component:  Build System      |          Version:  7.7
      Resolution:                    |         Keywords:
Operating System:  Unknown/Multiple  |     Architecture:  Unknown/Multiple
 Type of failure:  None/Unknown      |       Difficulty:  Unknown
       Test Case:                    |       Blocked By:
        Blocking:                    |  Related Tickets:
-------------------------------------+------------------------------------

Comment (by Austin Seipp <aseipp@…>):

 In [changeset:9e133b9dccec0553c6ec302d6ca0d3bc5eea06c4/ghc]:
 {{{
 #!CommitTicketReference repository="ghc"
 revision="9e133b9dccec0553c6ec302d6ca0d3bc5eea06c4"
 Make sure -fcmm-sink is passed to Parser properly

 Parser.hs needs to be compiled with -fcmm-sink on x86 platforms, so the
 register allocator doesn't run out of stack slots. Previously, we had to
 do some CPP hacks in order to emit an #ifdef into the file - this is
 because we preprocess it once up front, and run the preprocessor again
 when we compile it.

 There's two cases: the boostrap compiler is > 7.8, and the stage1 parser
 needs the flag, or the stage1 compiler is compiling the stage2
 Parser.hs, and needs the flag..

 The previous approach was super fragile with Clang. The more principled
 fix is to instead do this through the build system.

 This fixes #8182.

 Signed-off-by: Austin Seipp <aseipp at pobox.com>
 }}}

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




More information about the ghc-tickets mailing list