javascript Nodejs 分析:如何处理 v8.log 文件
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/21357963/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
Nodejs Profiling: What to do with v8.log file
提问by RainingChain
Only thing I have installed is Nodejs. I'm using Windows 8 x64.
我唯一安装的是Nodejs。我正在使用 Windows 8 x64。
I run my program via node --prof app.js
. It generates a v8.log file.
我通过node --prof app.js
. 它生成一个 v8.log 文件。
Now, what do I do with the v8.log file?
现在,我该如何处理 v8.log 文件?
回答by quibusus
Starting with v5.2.0, Node.JS ships with a built-in tick processor:
从 v5.2.0 开始,Node.JS 带有一个内置的滴答处理器:
node --prof-process
See the release notesfor more information.
有关更多信息,请参阅发行说明。
回答by rjz
Chrome's built-in Trace Event Profiling Tool(accessible in Chrome or Chromium at chrome://tracing) can build more-useful visualizations around v8.log output.
Chrome 的内置跟踪事件分析工具(可在 Chrome 或 Chromium 中访问 chrome://tracing)可以围绕 v8.log 输出构建更有用的可视化。
Note that dumps from node >= 0.11.x may be more useful to youthan those on the current stable release (0.10.35).
回答by kierans
You need to process the v8.log. The v8 log contains sample points, and want to collect that data into something readable/usable. Check out node-tick-processorand run that over your v8 log.
您需要处理 v8.log。v8 日志包含样本点,并希望将该数据收集为可读/可用的内容。查看node-tick-processor并在 v8 日志上运行它。