Commit 969d43e7 authored by sgjesse@chromium.org's avatar sgjesse@chromium.org

Changed all log messages to be handled through the LogMessageBuilder instead...

Changed all log messages to be handled through the LogMessageBuilder instead of through fprintf directly to the log file.

Added a flag for the runtime %Log call and fixed its arguments checking. Use of %Log is only for debugging.
Review URL: http://codereview.chromium.org/21406

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@1290 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
parent 8cd31d29
......@@ -315,6 +315,7 @@ DEFINE_bool(trace_regexp_assembler, false,
DEFINE_bool(log, false,
"Minimal logging (no API, code, GC, suspect, or handles samples).")
DEFINE_bool(log_all, false, "Log all events to the log file.")
DEFINE_bool(log_runtime, false, "Activate runtime system %Log call.")
DEFINE_bool(log_api, false, "Log API events to the log file.")
DEFINE_bool(log_code, false,
"Log code events to the log file without profiling.")
......
This diff is collapsed.
......@@ -218,8 +218,6 @@ class Logger {
// Emits the source code of a regexp. Used by regexp events.
static void LogRegExpSource(Handle<JSRegExp> regexp);
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);
......
......@@ -6037,9 +6037,9 @@ static Object* Runtime_ListNatives(Arguments args) {
static Object* Runtime_Log(Arguments args) {
ASSERT(args.length() == 2);
String* format = String::cast(args[0]);
CONVERT_CHECKED(String, format, args[0]);
CONVERT_CHECKED(JSArray, elms, args[1]);
Vector<const char> chars = format->ToAsciiVector();
JSArray* elms = JSArray::cast(args[1]);
Logger::LogRuntime(chars, elms);
return Heap::undefined_value();
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment