src: only start idle notifier when profiling
authorBen Noordhuis <info@bnoordhuis.nl>
Thu, 3 Oct 2013 08:45:32 +0000 (10:45 +0200)
committerBen Noordhuis <info@bnoordhuis.nl>
Thu, 3 Oct 2013 14:50:54 +0000 (16:50 +0200)
commit9566fe82cddda5b7fe59ace8f8d8851cf9d87268
tree815a7206072cd5b9459e9a95b43eb50d80edfe2c
parent57231d5286b036f3277e778eca5c4501c99b9ce0
src: only start idle notifier when profiling

The previous commit adds a notifier that tells the V8 profiler when
node.js is idle, i.e. when it's about to start sleeping in the
platform's equivalent of epoll_wait().

This commit adds a heuristic that only starts the notifier when the
V8 profiler is started from the command line.
src/node.cc