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

Unified Diff: src/log.h

Issue 17203: Periodic merge from bleeding_edge to experimental code generator... (Closed) Base URL: http://v8.googlecode.com/svn/branches/experimental/toiger/
Patch Set: Created 11 years, 11 months 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 | « src/jsregexp.cc ('k') | src/log.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/log.h
===================================================================
--- src/log.h (revision 1032)
+++ src/log.h (working copy)
@@ -72,7 +72,11 @@
#undef LOG
#ifdef ENABLE_LOGGING_AND_PROFILING
-#define LOG(Call) v8::internal::Logger::Call
+#define LOG(Call) \
+ do { \
+ if (v8::internal::Logger::is_enabled()) \
+ v8::internal::Logger::Call; \
+ } while (false)
#else
#define LOG(Call) ((void) 0)
#endif
@@ -189,9 +193,8 @@
static void RegExpCompileEvent(Handle<JSRegExp> regexp, bool in_cache);
- static void RegExpExecEvent(Handle<JSRegExp> regexp,
- int start_index,
- Handle<String> input_string);
+ // Log an event reported from generated code
+ static void LogRuntime(Vector<const char> format, JSArray* args);
#ifdef ENABLE_LOGGING_AND_PROFILING
static StateTag state() {
@@ -199,13 +202,15 @@
}
#endif
+ static bool is_enabled() { return logfile_ != NULL; }
+
#ifdef ENABLE_LOGGING_AND_PROFILING
private:
// Emits the source code of a regexp. Used by regexp events.
static void LogRegExpSource(Handle<JSRegExp> regexp);
- static void LogString(Handle<String> str);
+ static void LogString(Handle<String> str, bool show_impl_info);
// Emits a profiler tick event. Used by the profiler thread.
static void TickEvent(TickSample* sample, bool overflow);
« no previous file with comments | « src/jsregexp.cc ('k') | src/log.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698