Browse Source

v8: add %p option to --logfile, expands to pid

Useful when you are profiling multiple instances of V8 concurrently.
Submitted upstream: http://code.google.com/p/v8/issues/detail?id=2503

Refs #4617.
v0.9.7-release
Ben Noordhuis 12 years ago
parent
commit
8b0f3ce397
  1. 3
      deps/v8/src/log-utils.cc

3
deps/v8/src/log-utils.cc

@ -107,6 +107,9 @@ void Log::Initialize() {
// one character so we can escape the loop properly. // one character so we can escape the loop properly.
p--; p--;
break; break;
case 'p':
stream.Add("%d", OS::GetCurrentProcessId());
break;
case 't': { case 't': {
// %t expands to the current time in milliseconds. // %t expands to the current time in milliseconds.
double time = OS::TimeCurrentMillis(); double time = OS::TimeCurrentMillis();

Loading…
Cancel
Save