mirror of
https://github.com/jlfwong/speedscope.git
synced 2024-11-27 01:53:17 +03:00
274110a46b
#33 added support for importing from instruments indirectly via opening instruments and using the deep copy command. This PR adds support for importing `.trace` files directly, though only for time profiles specifically, and only for the highest sample count thread in the profile.
This PR adds `.trace` files from Instruments 9, and adds support for importing from either Instruments 8 and 9. The only major difference in the file format seems to be that Instruments 9 applies raw `zlib` compression generously throughout the file.
This PR also adds example `.trace` files for memory allocations, which are not supported for direct import. They use a totally different storage format for recording memory allocations, and I haven't yet figured out how that list of allocations references their corresponding callstack.
Lastly, this PR also adds examples from Instruments 7 since I happen to have a machine with an old version of Instruments. Import from Instruments 7 probably wouldn't be hard to add, but I haven't done that in this PR.
This currently only works in Chrome, and only via drag-and-drop of the files.
To test, drag the decompressed `simple-time-profile.trace` from 6016d970b9/sample/profiles/Instruments/9.3.1/simple-time-profile.trace.zip
onto speedscope.
The result should be this:
![image](https://user-images.githubusercontent.com/150329/40162338-8fa13502-5968-11e8-8fb3-40626e41884a.png)
Fixes #15
34 lines
820 B
JSON
34 lines
820 B
JSON
{
|
|
"name": "speedscope",
|
|
"version": "1.0.0",
|
|
"description": "",
|
|
"main": "index.js",
|
|
"scripts": {
|
|
"deploy": "./deploy.sh",
|
|
"prettier": "prettier --write './**/*.ts' './**/*.tsx'",
|
|
"lint": "eslint './**/*.ts' './**/*.tsx'",
|
|
"test": "npm run lint",
|
|
"serve": "parcel index.html --open --no-autoinstall"
|
|
},
|
|
"browserslist": [
|
|
"last 2 Chrome versions",
|
|
"last 2 Firefox versions"
|
|
],
|
|
"author": "",
|
|
"license": "MIT",
|
|
"devDependencies": {
|
|
"aphrodite": "2.1.0",
|
|
"eslint": "^4.19.1",
|
|
"eslint-plugin-prettier": "^2.6.0",
|
|
"parcel-bundler": "1.7.0",
|
|
"preact": "8.2.7",
|
|
"prettier": "^1.12.0",
|
|
"regl": "1.3.1",
|
|
"typescript": "2.8.1",
|
|
"typescript-eslint-parser": "^14.0.0",
|
|
"uglify-es": "3.2.2",
|
|
"@types/pako": "1.0.0",
|
|
"pako": "1.0.6"
|
|
}
|
|
}
|