#6103: Interrupted program cannot produce biographical heap profile
---------------------------+------------------------------------------------
Reporter: konn | Owner:
Type: bug | Status: new
Priority: normal | Component: Profiling
Version: 7.4.1 | Keywords:
Os: MacOS X | Architecture: x86_64 (amd64)
Failure: Runtime crash | Testcase:
Blockedby: | Blocking:
Related: |
---------------------------+------------------------------------------------
If I interrupt program running with "+RTS -p -hb" option, the program
aborts with message below and I could only get empty heap profile.
Minimal case is below:
{{{
module Main where
main :: IO ()
main = print $ sum [1..10000000000]
}}}
I compiled this code with "-prof -rtsopts" options, ran the program and
then interrupt after several seconds.
{{{
$ ghc http-biographic-profile.hs -prof -rtsopts
[1 of 1] Compiling Main ( http-biographic-profile.hs, http-
biographic-profile.o )
Linking biographic-profile ...
$ ./http-biographic-profile +RTS -hb -p
^Chttp-biographic-profile: internal error: Invalid object in
processHeapClosureForDead(): 58
(GHC version 7.0.4 for x86_64_apple_darwin)
Please report this as a GHC bug:
http://www.haskell.org/ghc/reportabug
zsh: abort ./http-biographic-profile +RTS -hb -p
}}}
Empty heap profile generated is below:
{{{
JOB "biographic-profile +RTS -hb -p"
DATE "Thu May 17 17:12 2012"
SAMPLE_UNIT "seconds"
VALUE_UNIT "bytes"
BEGIN_SAMPLE 0.00
END_SAMPLE 0.00
}}}
I reproduce this behaviour in environments below:
* GHC-7.0.4 (x86_64_apple_darwin, OS X 10.6.8, distributed with haskell-
platform 2011.3.0.0)
* GHC-7.4.1 (x86_64_apple_darwin, OS X 10.6.8, installed from tarball,
sandboxed with virthualenv)
I think "-hb" show work even when program interrupted, because "-hy",
"-hd", "-hr" and so on works in such a situation. Is this a intended
behaviour?
--
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/6103>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
_______________________________________________
Glasgow-haskell-bugs mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs