[GHC] #14997: mut_list_size calculation is off
GHC
ghc-devs at haskell.org
Tue Apr 3 12:29:18 UTC 2018
#14997: mut_list_size calculation is off
-------------------------------------+-------------------------------------
Reporter: osa1 | Owner: (none)
Type: bug | Status: new
Priority: lowest | Milestone:
Component: Runtime | Version: 8.5
System |
Keywords: | Operating System: Unknown/Multiple
Architecture: | Type of failure: None/Unknown
Unknown/Multiple |
Test Case: | Blocked By:
Blocking: | Related Tickets:
Differential Rev(s): | Wiki Page:
-------------------------------------+-------------------------------------
Program:
{{{
main = print (foldr (+) 0 [ 0 .. 10000 ] :: Int)
}}}
Compile:
{{{
$ ghc-stage2 Main.hs -debug -rtsopts -O0
}}}
Run:
{{{
$ ./Main +RTS -Dg
}}}
It prints something like
{{{
mut_list_size: 16 (0 vars, 0 arrays, 0 MVARs, 0 TVARs, 0
TVAR_WATCH_QUEUEs, 0 TREC_CHUNKs, 0 TREC_HEADERs, 0 ATOMIC_INVARIANTs, 0
INVARIANT_CHECK_QUEUEs, 0 others)
}}}
So there are two objects in the mut list, but `scavenge_mutable_list`
wasn't able to find anything. This is curious, and it seems like a bug.
Pretty much any program has this bug, `mut_list_size` and sum of objects
found in the mut list never match.
--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/14997>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the ghc-tickets
mailing list