Report approximated duration in milliseconds for profile nodes.
authormikhail.naganov@gmail.com <mikhail.naganov@gmail.com@ce2b1a6d-e550-0410-aec6-3dcde31c8c00>
Thu, 15 Apr 2010 11:37:29 +0000 (11:37 +0000)
committermikhail.naganov@gmail.com <mikhail.naganov@gmail.com@ce2b1a6d-e550-0410-aec6-3dcde31c8c00>
Thu, 15 Apr 2010 11:37:29 +0000 (11:37 +0000)
commit61085478c68df1289b570298e008cebe4c808fec
treec91969467a699daac49a5e39897e457959e74184
parentafc15bb48fadd0ddc727d467b7a2f33a1cfec6d6
Report approximated duration in milliseconds for profile nodes.

The simple formula "ms = ticks * sampler_interval" doesn't work,
because e.g. on Linux, the actual sampling rate can be 5 times
lower than the one set up in the code. To calculate actual sampling
rate, current time is periodically queried and processed along with
actual sampling ticks count.

Review URL: http://codereview.chromium.org/1539038

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@4427 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
src/api.cc
src/cpu-profiler-inl.h
src/cpu-profiler.cc
src/log.h
src/profile-generator-inl.h
src/profile-generator.cc
src/profile-generator.h
test/cctest/test-cpu-profiler.cc
test/cctest/test-profile-generator.cc