Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Profiling nodejs with v8

I have a node application which i want to profile using the node profiler.

So first i ran:

node --prof v8test.js

Then, I downloaded the v8 tools

svn checkout http://v8.googlecode.com/svn/trunk/ v8;
make dependencies;
make native;

Then tried to analyze the file created (v8.log)

tools/linux-tick-processor ../v8.log

But i get a lot of:

Code move event for unknown code: 0x289dd8475560
Code move event for unknown code: 0x289dd84758e0
Code move event for unknown code: 0x289dd8479280
Code move event for unknown code: 0x289dd8482980
Code move event for unknown code: 0x289dd84c2a80
line 718730: unknown code state: undefined
line 718731: unknown code state: undefined
line 739575: unknown code state: undefined
line 739577: unknown code state: undefined

Can anybody help me figure out what's going on ?

like image 539
Kurt Agius Avatar asked Mar 21 '13 14:03

Kurt Agius


1 Answers

The log file format seems to change quite frequently, so you need to make sure that you are using the right version of v8. For instance, if the profile log was generated with node v0.10.18, you have to analyse it with the tick processor for v8 version 3.14.5. To find out which version of v8 a given version of node is built on, you can check deps/v8/ChangeLog in the node source distribution (node's own changelog seems to be a little unreliable in this respect).

like image 174
xiemaisi Avatar answered Oct 22 '22 04:10

xiemaisi