jlfwong / speedscope

🔬 A fast, interactive web-based viewer for performance profiles.
https://www.speedscope.app
MIT License
5.52k stars 241 forks source link

"Unrecognized format" error when trying to import from Chrome. #162

Closed dyuval92 closed 6 years ago

dyuval92 commented 6 years ago

I tried to use speedscope with .json profile file which I recorded with Chrome and it showed "unrecognized format!" error. Every time this error is shown there is an output in the console "Timer 'import' already exists". I also tried to upload profiling file from my application, which is in trace event format, to speedscope and it showed exact same error. At the same time both files work fine with chrome:\tracing tool.

What do you think could be wrong with the file?

chrome_test.txt

jlfwong commented 6 years ago

Hi @dyuval92!

How are you capturing this trace? From looking at the file, it doesn't contain CPUProfile or Profile or ProfileChunk anywhere, at least one of which I'd expect to see if this was a profile recorded with Chrome developer tools (https://developers.google.com/web/tools/chrome-devtools/evaluate-performance/).

speedscope supports import from chrome developer tools, but not from chrome://tracing. Support for chrome://tracing is requested in #77.

jlfwong commented 6 years ago

When I load this via chrome developer tools itself, it also contains no CPU profiling information, so there'd be nothing for speedscope to display here. I'm going to close this for now, and you can voice your support in #77, since I believe that's the relevant issue. Let me know if I've misunderstood!

dyuval92 commented 6 years ago

I was capturing this trace on speedscope.app page. I've looked into the output .json file and, indeed, it didn't have "ProfileChunk" defined anywhere. However, this didn't cause any errors in the chrome://tracing therefore I assumed something else was wrong.

Thank you for your answer!