heapdump14
heapdump14 copied to clipboard
2015/09/16 23:02:31 unknown record kind 26311
Hi,
I'm using go 1.5.1 and a fork that puts 1.5 in the expected header at https://github.com/cep21/heapdump14 (https://github.com/cep21/heapdump14/commit/1d13a6e5b26f5e2678caa105f22c40041eade8bd) My program is a simple hello-world like app at https://github.com/cep21/heaptest/blob/master/main.go. I run it, then curl out a heap dump via
curl localhost:6060/debug/pprof/heapdump > /tmp/heapdump
which is an endpoint I wrote that calls WriteHeapDump().
When I run ./hview /tmp/heapdump ../../heaptest/heaptest
I get the following output:
Loading...
2015/09/16 23:07:09 unknown record kind 26311
I would post my actual heapdump but it's 278MB :( I hope you can reproduce it via the test application above. I'm doing this on a mac, if that matters.
I have a smaller example dump at https://github.com/cep21/heaptest/blob/master/example_dumps/heapdump2 which produces this output:
< ./hview heapdump2
Loading...
2015/09/16 23:17:29 unexpected EOF
I too forked this to see about running this against 1.5 compiles. It checks to see if the dmp file has either the 1.4 or the 1.5 header. https://github.com/randall77/heapdump14/commit/1f1d3e7b78982a2a60d1990c5b93a43c10d38df6
It appears that checking for the 1.5 header string is not sufficient to get heapdump14 working with 1.5; running it against a dump of a simple application compiled with 1.5 results in an error due to type information mismatch. This only occurs if the optional application binary is provided.
My error message adds the file and line number because I added flags to my heapdump14 so I could see where the errors were coming from.
Using hview
with both the dump and the binary:
Loading...
inferring types...
2015/09/19 01:48:01 parser.go:1565: Global variables...
2015/09/19 01:48:01 parser.go:1806: dwarf type strings.Replacer has iface, gc type PP does not
Using hview
with just the dump, no binary, it works as expected:
Loading...
Analyzing...
Grouping by type...
Computing referrers...
Computing dominators...
Ready. Point your browser to localhost:8080
This works in 1.4, with one non-fatal error
Loading...
inferring types...
2015/09/18 20:34:15 Global variables...
2015/09/18 20:34:15 Stacks...
2015/09/18 20:34:15 heap ptr c208065fc8 doesn't point to an object
Analyzing...
Grouping by type...
Computing referrers...
Computing dominators...
Ready. Point your browser to localhost:8080
I used the heapdump branch of my peu repo: https://github.com/mohae/peu/tree/heapdump
This branch has versions of peu
compiled with 1.4 and 1.5 along with their resulting heap dumps.
Trying this with a more complex application, hugo resulted in an unexpected EOF, like what cep21 reported.
Loading...
2015/09/19 02:04:41 parser.go:427: unexpected EOF
Hugo compiled on 1.4 resulted in different errors. I will add an issue for that.