Code Monkey home page Code Monkey logo

hprof2flamegraph's People

Contributors

cykl avatar pyrolistical avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

hprof2flamegraph's Issues

Support for Py3.x

Does supporting Python >= 2.7 mean that I can run this tool for Py3.6?
This is purely py2 --> py3 encoding problem.

$ stackcollapse-hprof mymem.hprof > output-folded.txt

Traceback (most recent call last):
  File "/Library/Frameworks/Python.framework/Versions/3.6/bin/stackcollapse-hprof", line 11, in <module>
    sys.exit(main())
  File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/stackcollapse_hprof.py", line 183, in main
    content  = get_file_content(filename)
  File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/stackcollapse_hprof.py", line 58, in get_file_content
    lines = f.readlines()
  File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/encodings/ascii.py", line 26, in decode
    return codecs.ascii_decode(input, self.errors)[0]
UnicodeDecodeError: 'ascii' codec can't decode byte 0xd6 in position 87: ordinal not in range(128)

UnicodeDecodeError

Hi,
I hava a file that generated on android,I convert it to a standard binary hprof by the tool "hprof-conv".stackcollapse-hprof use "utf-8" to read it,so error is showed:

    File "./stackcollapse_hprof.py", line 207, in <module>
      main()
    File "./stackcollapse_hprof.py", line 184, in main
      content  = get_file_content(filename)
    File "./stackcollapse_hprof.py", line 60, in get_file_content
      return f.read()
    File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/codecs.py", line 302, in decode
      (result, consumed) = self._buffer_decode(data, self.errors, final)
      UnicodeDecodeError: 'utf8' codec can't decode byte 0x99 in position 29: invalid start byte

Do you have a solution for android hprof?

stackcollapse-hpl fails with "Exception: Unexpected marker: 21 at offset 14"

I get the following error when trying to parse a hpl file generated by honest-profiler (version d505d540ad09516ede804e7d1aa34a889f266780):

stackcollapse-hpl slow2 > output-folded.txt
Traceback (most recent call last):
  File "/usr/local/bin/stackcollapse-hpl", line 9, in <module>
    load_entry_point('hprof2flamegraph==0.0.2', 'console_scripts', 'stackcollapse-hpl')()
  File "/usr/local/lib/python3.4/dist-packages/stackcollapse_hpl.py", line 110, in main
    (traces, methods) = parse_hpl(filename)
  File "/usr/local/lib/python3.4/dist-packages/stackcollapse_hpl.py", line 72, in parse_hpl
    raise Exception("Unexpected marker: %s at offset %s" % (marker, fh.tell()))
Exception: Unexpected marker: 21 at offset 14

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.