[GHC] #16291: Document or enable commented-out sanity check in checkStackChunk

GHC ghc-devs at haskell.org
Tue Mar 5 15:17:03 UTC 2019


#16291: Document or enable commented-out sanity check in checkStackChunk
-------------------------------------+-------------------------------------
        Reporter:  osa1              |                Owner:  (none)
            Type:  task              |               Status:  new
        Priority:  normal            |            Milestone:
       Component:  Compiler          |              Version:
      Resolution:                    |             Keywords:
Operating System:  Unknown/Multiple  |         Architecture:
                                     |  Unknown/Multiple
 Type of failure:  None/Unknown      |            Test Case:
      Blocked By:                    |             Blocking:
 Related Tickets:                    |  Differential Rev(s):
       Wiki Page:                    |
-------------------------------------+-------------------------------------
Changes (by bgamari):

 * type:  bug => task


Old description:

> `checkStackChunk` is currently defined like this:
>
> {{{
> void
> checkStackChunk( StgPtr sp, StgPtr stack_end )
> {
>     StgPtr p;
>
>     p = sp;
>     while (p < stack_end) {
>         p += checkStackFrame( p );
>     }
>     // ASSERT( p == stack_end ); -- HWL
> }
> }}}
>
> The commented-out assertion makes perfect sense to me, but I can't enable
> it
> (causes test failures), and it's not documented why it should not be
> enabled. I
> think this catches a bug that needs to be fixed.

New description:

 `checkStackChunk` is currently defined like this:

 {{{#!c
 void
 checkStackChunk( StgPtr sp, StgPtr stack_end )
 {
     StgPtr p;

     p = sp;
     while (p < stack_end) {
         p += checkStackFrame( p );
     }
     // ASSERT( p == stack_end ); -- HWL
 }
 }}}

 The commented-out assertion makes perfect sense to me, but I can't enable
 it
 (causes test failures), and it's not documented why it should not be
 enabled. I
 think this catches a bug that needs to be fixed.

--

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


More information about the ghc-tickets mailing list