{"id":13906984,"url":"https://github.com/thlorenz/turbolizer","last_synced_at":"2025-09-25T22:12:35.270Z","repository":{"id":40003186,"uuid":"128261929","full_name":"thlorenz/turbolizer","owner":"thlorenz","description":"Turbolizer tool from the v8 repository with added support to preload a profile","archived":false,"fork":false,"pushed_at":"2021-02-09T14:39:56.000Z","size":835,"stargazers_count":178,"open_issues_count":3,"forks_count":10,"subscribers_count":8,"default_branch":"master","last_synced_at":"2024-04-14T04:55:33.632Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://thlorenz.github.io/turbolizer","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/thlorenz.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2018-04-05T20:41:07.000Z","updated_at":"2024-03-06T22:47:46.000Z","dependencies_parsed_at":"2022-06-26T02:59:26.726Z","dependency_job_id":null,"html_url":"https://github.com/thlorenz/turbolizer","commit_stats":null,"previous_names":[],"tags_count":6,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thlorenz%2Fturbolizer","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thlorenz%2Fturbolizer/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thlorenz%2Fturbolizer/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thlorenz%2Fturbolizer/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/thlorenz","download_url":"https://codeload.github.com/thlorenz/turbolizer/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247635229,"owners_count":20970699,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-08-06T23:01:45.856Z","updated_at":"2025-09-25T22:12:35.180Z","avatar_url":"https://github.com/thlorenz.png","language":"JavaScript","funding_links":[],"categories":["JavaScript"],"sub_categories":[],"readme":"# Turbolizer\n\nTurbolizer tool derived from the one included with `v8/tools`.\n\n![turbolizer](./assets/turbolizer.gif)\n\n## Installation\n\n```\nnpm install -g turbolizer\n```\n\n## Usage\n\nRun your app with the `--trace-turbo` flag, i.e. `node --trace-turbo app.js` to produce `turbo-*.json` files.\n\nThen just run `turbolizer` in the same directory and select which file (or all) you want to\nload and the turbolizer application will open in the browser with it preloaded.\n\n## Alternatives\n\nIf you don't want to install anything, as an alternative can then either load them one by one\nvia the hosted browser version of this repo at [thlorenz.github.io/turbolizer](https://thlorenz.github.io/turbolizer).\n\n* * *\n\n_Original Readme from the [v8 repository](https://github.com/v8/v8)_\n\nTurbolizer\n==========\n\nTurbolizer is a HTML-based tool that visualizes optimized code along the various\nphases of Turbofan's optimization pipeline, allowing easy navigation between\nsource code, Turbofan IR graphs, scheduled IR nodes and generated assembly code.\n\nTurbolizer consumes .json files that are generated per-function by d8 by passing\nthe '--trace-turbo' command-line flag.\n\nHost the turbolizer locally by starting a web server that serves the contents of\nthe turbolizer directory, e.g.:\n\n    cd src/tools/turbolizer\n    python -m SimpleHTTPServer 8000\n\nOptionally, profiling data generated by the perf tools in linux can be merged\nwith the .json files using the turbolizer-perf.py file included. The following\ncommand is an example of using the perf script:\n\n    perf script -i perf.data.jitted -s turbolizer-perf.py turbo-main.json\n\nThe output of the above command is a json object that can be piped to a file\nwhich, when uploaded to turbolizer, will display the event counts from perf next\nto each instruction in the disassembly. Further detail can be found in the\nbottom of this document under \"Using Perf with Turbo.\"\n\nUsing the python interface in perf script requires python-dev to be installed\nand perf be recompiled with python support enabled. Once recompiled, the\nvariable PERF_EXEC_PATH must be set to the location of the recompiled perf\nbinaries.\n\nGraph visualization and manipulation based on Mike Bostock's sample code for an\ninteractive tool for creating directed graphs. Original source is at\nhttps://github.com/metacademy/directed-graph-creator and released under the\nMIT/X license.\n\nIcons derived from the \"White Olive Collection\" created by Breezi released under\nthe Creative Commons BY license.\n\nUsing Perf with Turbo\n---------------------\n\nIn order to generate perf data that matches exactly with the turbofan trace, you\nmust use either a debug build of v8 or a release build with the flag\n'disassembler=on'. This flag ensures that the '--trace-turbo' will output the\nnecessary disassembly for linking with the perf profile.\n\nThe basic example of generating the required data is as follows:\n\n    perf record -k mono /path/to/d8 --trace-turbo --perf-prof main.js\n    perf inject -j -i perf.data -o perf.data.jitted\n    perf script -i perf.data.jitted -s turbolizer-perf.py turbo-main.json\n\nThese commands combined will run and profile d8, merge the output into a single\n'perf.data.jitted' file, then take the event data from that and link them to the\ndisassembly in the 'turbo-main.json'. Note that, as above, the output of the\nscript command must be piped to a file for uploading to turbolizer.\n\nThere are many options that can be added to the first command, for example '-e'\ncan be used to specify the counting of specific events (default: cycles), as\nwell as '--cpu' to specify which CPU to sample.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fthlorenz%2Fturbolizer","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fthlorenz%2Fturbolizer","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fthlorenz%2Fturbolizer/lists"}