Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(883)

Unified Diff: src/log-utils.cc

Issue 806143002: Log V8 version in profiler log file (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 6 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | test/cctest/test-log.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/log-utils.cc
diff --git a/src/log-utils.cc b/src/log-utils.cc
index c94d07a9f29220fab5caeb252381c35821f6970c..278cff1fc8ba93293953f0cf911c5821d8564c6f 100644
--- a/src/log-utils.cc
+++ b/src/log-utils.cc
@@ -6,6 +6,7 @@
#include "src/log-utils.h"
#include "src/string-stream.h"
+#include "src/version.h"
namespace v8 {
namespace internal {
@@ -49,6 +50,14 @@ void Log::Initialize(const char* log_file_name) {
} else {
OpenFile(log_file_name);
}
+
+ if (output_handle_ != nullptr) {
+ Log::MessageBuilder msg(this);
+ msg.Append("v8-version,%d,%d,%d,%d,%d", Version::GetMajor(),
+ Version::GetMinor(), Version::GetBuild(), Version::GetPatch(),
+ Version::IsCandidate());
+ msg.WriteToLogFile();
+ }
}
}
« no previous file with comments | « no previous file | test/cctest/test-log.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698