Revision: 21160
Author:   [email protected]
Date:     Tue May  6 09:28:08 2014 UTC
Log:      Remove broken %_Log functionality.

[email protected]
BUG=

Review URL: https://codereview.chromium.org/265283007
http://code.google.com/p/v8/source/detail?r=21160

Modified:
 /branches/bleeding_edge/src/arm/full-codegen-arm.cc
 /branches/bleeding_edge/src/arm/macro-assembler-arm.cc
 /branches/bleeding_edge/src/arm/macro-assembler-arm.h
 /branches/bleeding_edge/src/arm64/full-codegen-arm64.cc
 /branches/bleeding_edge/src/arm64/macro-assembler-arm64.cc
 /branches/bleeding_edge/src/codegen.cc
 /branches/bleeding_edge/src/codegen.h
 /branches/bleeding_edge/src/flag-definitions.h
 /branches/bleeding_edge/src/hydrogen.cc
 /branches/bleeding_edge/src/ia32/full-codegen-ia32.cc
 /branches/bleeding_edge/src/ia32/macro-assembler-ia32.cc
 /branches/bleeding_edge/src/ia32/macro-assembler-ia32.h
 /branches/bleeding_edge/src/log-utils.cc
 /branches/bleeding_edge/src/log-utils.h
 /branches/bleeding_edge/src/log.cc
 /branches/bleeding_edge/src/log.h
 /branches/bleeding_edge/src/mips/full-codegen-mips.cc
 /branches/bleeding_edge/src/mips/macro-assembler-mips.cc
 /branches/bleeding_edge/src/mips/macro-assembler-mips.h
 /branches/bleeding_edge/src/regexp.js
 /branches/bleeding_edge/src/runtime.cc
 /branches/bleeding_edge/src/runtime.h
 /branches/bleeding_edge/src/string.js
 /branches/bleeding_edge/src/x64/full-codegen-x64.cc
 /branches/bleeding_edge/src/x64/macro-assembler-x64.cc
 /branches/bleeding_edge/src/x64/macro-assembler-x64.h

=======================================
--- /branches/bleeding_edge/src/arm/full-codegen-arm.cc Wed Apr 30 14:33:35 2014 UTC +++ /branches/bleeding_edge/src/arm/full-codegen-arm.cc Tue May 6 09:28:08 2014 UTC
@@ -3327,28 +3327,6 @@

   context()->Plug(r0);
 }
-
-
-void FullCodeGenerator::EmitLog(CallRuntime* expr) {
-  // Conditionally generate a log call.
-  // Args:
-  //   0 (literal string): The type of logging (corresponds to the flags).
-  //     This is used to determine whether or not to generate the log call.
-  //   1 (string): Format string.  Access the string at argument index 2
-  //     with '%2s' (see Logger::LogRuntime for all the formats).
-  //   2 (array): Arguments to the format string.
-  ZoneList<Expression*>* args = expr->arguments();
-  ASSERT_EQ(args->length(), 3);
-  if (CodeGenerator::ShouldGenerateLog(isolate(), args->at(0))) {
-    VisitForStackValue(args->at(1));
-    VisitForStackValue(args->at(2));
-    __ CallRuntime(Runtime::kHiddenLog, 2);
-  }
-
-  // Finally, we're expected to leave a value on the top of the stack.
-  __ LoadRoot(r0, Heap::kUndefinedValueRootIndex);
-  context()->Plug(r0);
-}


 void FullCodeGenerator::EmitSubString(CallRuntime* expr) {
=======================================
--- /branches/bleeding_edge/src/arm/macro-assembler-arm.cc Wed Apr 30 09:50:58 2014 UTC +++ /branches/bleeding_edge/src/arm/macro-assembler-arm.cc Tue May 6 09:28:08 2014 UTC
@@ -2445,14 +2445,6 @@
 bool MacroAssembler::AllowThisStubCall(CodeStub* stub) {
   return has_frame_ || !stub->SometimesSetsUpAFrame();
 }
-
-
-void MacroAssembler::IllegalOperation(int num_arguments) {
-  if (num_arguments > 0) {
-    add(sp, sp, Operand(num_arguments * kPointerSize));
-  }
-  LoadRoot(r0, Heap::kUndefinedValueRootIndex);
-}


 void MacroAssembler::IndexFromHash(Register hash, Register index) {
@@ -2650,10 +2642,7 @@
   // If the expected number of arguments of the runtime function is
   // constant, we check that the actual number of arguments match the
   // expectation.
-  if (f->nargs >= 0 && f->nargs != num_arguments) {
-    IllegalOperation(num_arguments);
-    return;
-  }
+  CHECK(f->nargs < 0 || f->nargs == num_arguments);

   // TODO(1236192): Most runtime routines don't need the number of
   // arguments passed in because it is constant. At some point we
=======================================
--- /branches/bleeding_edge/src/arm/macro-assembler-arm.h Wed Apr 30 09:50:58 2014 UTC +++ /branches/bleeding_edge/src/arm/macro-assembler-arm.h Tue May 6 09:28:08 2014 UTC
@@ -930,10 +930,6 @@
   }


-  // Generates code for reporting that an illegal operation has
-  // occurred.
-  void IllegalOperation(int num_arguments);
-
   // Picks out an array index from the hash field.
   // Register use:
   //   hash - holds the index's hash. Clobbered.
=======================================
--- /branches/bleeding_edge/src/arm64/full-codegen-arm64.cc Wed Apr 30 14:33:35 2014 UTC +++ /branches/bleeding_edge/src/arm64/full-codegen-arm64.cc Tue May 6 09:28:08 2014 UTC
@@ -3063,28 +3063,6 @@

   context()->Plug(x0);
 }
-
-
-void FullCodeGenerator::EmitLog(CallRuntime* expr) {
-  // Conditionally generate a log call.
-  // Args:
-  //   0 (literal string): The type of logging (corresponds to the flags).
-  //     This is used to determine whether or not to generate the log call.
-  //   1 (string): Format string.  Access the string at argument index 2
-  //     with '%2s' (see Logger::LogRuntime for all the formats).
-  //   2 (array): Arguments to the format string.
-  ZoneList<Expression*>* args = expr->arguments();
-  ASSERT_EQ(args->length(), 3);
-  if (CodeGenerator::ShouldGenerateLog(isolate(), args->at(0))) {
-    VisitForStackValue(args->at(1));
-    VisitForStackValue(args->at(2));
-    __ CallRuntime(Runtime::kHiddenLog, 2);
-  }
-
-  // Finally, we're expected to leave a value on the top of the stack.
-  __ LoadRoot(x0, Heap::kUndefinedValueRootIndex);
-  context()->Plug(x0);
-}


 void FullCodeGenerator::EmitSubString(CallRuntime* expr) {
=======================================
--- /branches/bleeding_edge/src/arm64/macro-assembler-arm64.cc Tue May 6 08:05:27 2014 UTC +++ /branches/bleeding_edge/src/arm64/macro-assembler-arm64.cc Tue May 6 09:28:08 2014 UTC
@@ -1673,14 +1673,7 @@

   // Check that the number of arguments matches what the function expects.
// If f->nargs is -1, the function can accept a variable number of arguments.
-  if (f->nargs >= 0 && f->nargs != num_arguments) {
-    // Illegal operation: drop the stack arguments and return undefined.
-    if (num_arguments > 0) {
-      Drop(num_arguments);
-    }
-    LoadRoot(x0, Heap::kUndefinedValueRootIndex);
-    return;
-  }
+  CHECK(f->nargs < 0 || f->nargs == num_arguments);

   // Place the necessary arguments.
   Mov(x0, num_arguments);
=======================================
--- /branches/bleeding_edge/src/codegen.cc      Tue Apr 29 06:42:26 2014 UTC
+++ /branches/bleeding_edge/src/codegen.cc      Tue May  6 09:28:08 2014 UTC
@@ -163,21 +163,6 @@
   }
 #endif  // ENABLE_DISASSEMBLER
 }
-
-
-bool CodeGenerator::ShouldGenerateLog(Isolate* isolate, Expression* type) {
-  ASSERT(type != NULL);
-  if (!isolate->logger()->is_logging() &&
-      !isolate->cpu_profiler()->is_profiling()) {
-    return false;
-  }
-  Handle<String> name = Handle<String>::cast(type->AsLiteral()->value());
-  if (FLAG_log_regexp) {
-    if (name->IsOneByteEqualTo(STATIC_ASCII_VECTOR("regexp")))
-      return true;
-  }
-  return false;
-}


 bool CodeGenerator::RecordPositions(MacroAssembler* masm,
=======================================
--- /branches/bleeding_edge/src/codegen.h       Tue Apr 29 06:42:26 2014 UTC
+++ /branches/bleeding_edge/src/codegen.h       Tue May  6 09:28:08 2014 UTC
@@ -79,8 +79,6 @@
   // Print the code after compiling it.
   static void PrintCode(Handle<Code> code, CompilationInfo* info);

-  static bool ShouldGenerateLog(Isolate* isolate, Expression* type);
-
   static bool RecordPositions(MacroAssembler* masm,
                               int pos,
                               bool right_here = false);
=======================================
--- /branches/bleeding_edge/src/flag-definitions.h Mon May 5 16:33:23 2014 UTC +++ /branches/bleeding_edge/src/flag-definitions.h Tue May 6 09:28:08 2014 UTC
@@ -776,7 +776,6 @@
 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.")
=======================================
--- /branches/bleeding_edge/src/hydrogen.cc     Tue May  6 07:05:07 2014 UTC
+++ /branches/bleeding_edge/src/hydrogen.cc     Tue May  6 09:28:08 2014 UTC
@@ -10794,12 +10794,6 @@
       New<HCompareObjectEqAndBranch>(left, right);
   return ast_context()->ReturnControl(result, call->id());
 }
-
-
-void HOptimizedGraphBuilder::GenerateLog(CallRuntime* call) {
-  // %_Log is ignored in optimized code.
-  return ast_context()->ReturnValue(graph()->GetConstantUndefined());
-}


 // Fast support for StringAdd.
=======================================
--- /branches/bleeding_edge/src/ia32/full-codegen-ia32.cc Wed Apr 30 14:33:35 2014 UTC +++ /branches/bleeding_edge/src/ia32/full-codegen-ia32.cc Tue May 6 09:28:08 2014 UTC
@@ -3277,27 +3277,6 @@

   context()->Plug(eax);
 }
-
-
-void FullCodeGenerator::EmitLog(CallRuntime* expr) {
-  // Conditionally generate a log call.
-  // Args:
-  //   0 (literal string): The type of logging (corresponds to the flags).
-  //     This is used to determine whether or not to generate the log call.
-  //   1 (string): Format string.  Access the string at argument index 2
-  //     with '%2s' (see Logger::LogRuntime for all the formats).
-  //   2 (array): Arguments to the format string.
-  ZoneList<Expression*>* args = expr->arguments();
-  ASSERT_EQ(args->length(), 3);
-  if (CodeGenerator::ShouldGenerateLog(isolate(), args->at(0))) {
-    VisitForStackValue(args->at(1));
-    VisitForStackValue(args->at(2));
-    __ CallRuntime(Runtime::kHiddenLog, 2);
-  }
-  // Finally, we're expected to leave a value on the top of the stack.
-  __ mov(eax, isolate()->factory()->undefined_value());
-  context()->Plug(eax);
-}


 void FullCodeGenerator::EmitSubString(CallRuntime* expr) {
=======================================
--- /branches/bleeding_edge/src/ia32/macro-assembler-ia32.cc Wed Apr 30 09:50:58 2014 UTC +++ /branches/bleeding_edge/src/ia32/macro-assembler-ia32.cc Tue May 6 09:28:08 2014 UTC
@@ -2177,14 +2177,6 @@
 bool MacroAssembler::AllowThisStubCall(CodeStub* stub) {
   return has_frame_ || !stub->SometimesSetsUpAFrame();
 }
-
-
-void MacroAssembler::IllegalOperation(int num_arguments) {
-  if (num_arguments > 0) {
-    add(esp, Immediate(num_arguments * kPointerSize));
-  }
-  mov(eax, Immediate(isolate()->factory()->undefined_value()));
-}


 void MacroAssembler::IndexFromHash(Register hash, Register index) {
@@ -2212,10 +2204,7 @@
   // If the expected number of arguments of the runtime function is
   // constant, we check that the actual number of arguments match the
   // expectation.
-  if (f->nargs >= 0 && f->nargs != num_arguments) {
-    IllegalOperation(num_arguments);
-    return;
-  }
+  CHECK(f->nargs < 0 || f->nargs == num_arguments);

   // TODO(1236192): Most runtime routines don't need the number of
   // arguments passed in because it is constant. At some point we
=======================================
--- /branches/bleeding_edge/src/ia32/macro-assembler-ia32.h Tue Apr 29 06:42:26 2014 UTC +++ /branches/bleeding_edge/src/ia32/macro-assembler-ia32.h Tue May 6 09:28:08 2014 UTC
@@ -702,10 +702,6 @@
                                Label* miss,
                                bool miss_on_bound_function = false);

-  // Generates code for reporting that an illegal operation has
-  // occurred.
-  void IllegalOperation(int num_arguments);
-
   // Picks out an array index from the hash field.
   // Register use:
   //   hash - holds the index's hash. Clobbered.
=======================================
--- /branches/bleeding_edge/src/log-utils.cc    Tue Apr 29 06:42:26 2014 UTC
+++ /branches/bleeding_edge/src/log-utils.cc    Tue May  6 09:28:08 2014 UTC
@@ -28,7 +28,6 @@

   // --log-all enables all the log flags.
   if (FLAG_log_all) {
-    FLAG_log_runtime = true;
     FLAG_log_api = true;
     FLAG_log_code = true;
     FLAG_log_gc = true;
=======================================
--- /branches/bleeding_edge/src/log-utils.h     Tue Apr 29 06:42:26 2014 UTC
+++ /branches/bleeding_edge/src/log-utils.h     Tue May  6 09:28:08 2014 UTC
@@ -22,10 +22,10 @@
   void stop() { is_stopped_ = true; }

   static bool InitLogAtStart() {
-    return FLAG_log || FLAG_log_runtime || FLAG_log_api
- || FLAG_log_code || FLAG_log_gc || FLAG_log_handles || FLAG_log_suspect
-        || FLAG_log_regexp || FLAG_ll_prof || FLAG_perf_basic_prof
-        || FLAG_perf_jit_prof || FLAG_log_internal_timer_events;
+    return FLAG_log || FLAG_log_api || FLAG_log_code || FLAG_log_gc
+        || FLAG_log_handles || FLAG_log_suspect || FLAG_log_regexp
+        || FLAG_ll_prof || FLAG_perf_basic_prof || FLAG_perf_jit_prof
+        || FLAG_log_internal_timer_events;
   }

   // Frees all resources acquired in Initialize and Open... functions.
=======================================
--- /branches/bleeding_edge/src/log.cc  Wed Apr 30 14:33:35 2014 UTC
+++ /branches/bleeding_edge/src/log.cc  Tue May  6 09:28:08 2014 UTC
@@ -1176,47 +1176,6 @@
   msg.Append(in_cache ? ",hit\n" : ",miss\n");
   msg.WriteToLogFile();
 }
-
-
-void Logger::LogRuntime(Vector<const char> format,
-                        Handle<JSArray> args) {
-  if (!log_->IsEnabled() || !FLAG_log_runtime) return;
-  Log::MessageBuilder msg(log_);
-  for (int i = 0; i < format.length(); i++) {
-    char c = format[i];
-    if (c == '%' && i <= format.length() - 2) {
-      i++;
-      ASSERT('0' <= format[i] && format[i] <= '9');
- // No exception expected when getting an element from an array literal.
-      Handle<Object> obj = Object::GetElement(
-          isolate_, args, format[i] - '0').ToHandleChecked();
-      i++;
-      switch (format[i]) {
-        case 's':
-          msg.AppendDetailed(String::cast(*obj), false);
-          break;
-        case 'S':
-          msg.AppendDetailed(String::cast(*obj), true);
-          break;
-        case 'r':
-          Logger::LogRegExpSource(Handle<JSRegExp>::cast(obj));
-          break;
-        case 'x':
-          msg.Append("0x%x", Smi::cast(*obj)->value());
-          break;
-        case 'i':
-          msg.Append("%i", Smi::cast(*obj)->value());
-          break;
-        default:
-          UNREACHABLE();
-      }
-    } else {
-      msg.Append(c);
-    }
-  }
-  msg.Append('\n');
-  msg.WriteToLogFile();
-}


 void Logger::ApiIndexedSecurityCheck(uint32_t index) {
=======================================
--- /branches/bleeding_edge/src/log.h   Wed Apr 30 14:33:35 2014 UTC
+++ /branches/bleeding_edge/src/log.h   Tue May  6 09:28:08 2014 UTC
@@ -326,9 +326,6 @@

   void RegExpCompileEvent(Handle<JSRegExp> regexp, bool in_cache);

-  // Log an event reported from generated code
-  void LogRuntime(Vector<const char> format, Handle<JSArray> args);
-
   bool is_logging() {
     return is_logging_;
   }
=======================================
--- /branches/bleeding_edge/src/mips/full-codegen-mips.cc Wed Apr 30 20:19:45 2014 UTC +++ /branches/bleeding_edge/src/mips/full-codegen-mips.cc Tue May 6 09:28:08 2014 UTC
@@ -3346,28 +3346,6 @@

   context()->Plug(v0);
 }
-
-
-void FullCodeGenerator::EmitLog(CallRuntime* expr) {
-  // Conditionally generate a log call.
-  // Args:
-  //   0 (literal string): The type of logging (corresponds to the flags).
-  //     This is used to determine whether or not to generate the log call.
-  //   1 (string): Format string.  Access the string at argument index 2
-  //     with '%2s' (see Logger::LogRuntime for all the formats).
-  //   2 (array): Arguments to the format string.
-  ZoneList<Expression*>* args = expr->arguments();
-  ASSERT_EQ(args->length(), 3);
-  if (CodeGenerator::ShouldGenerateLog(isolate(), args->at(0))) {
-    VisitForStackValue(args->at(1));
-    VisitForStackValue(args->at(2));
-    __ CallRuntime(Runtime::kHiddenLog, 2);
-  }
-
-  // Finally, we're expected to leave a value on the top of the stack.
-  __ LoadRoot(v0, Heap::kUndefinedValueRootIndex);
-  context()->Plug(v0);
-}


 void FullCodeGenerator::EmitSubString(CallRuntime* expr) {
=======================================
--- /branches/bleeding_edge/src/mips/macro-assembler-mips.cc Tue Apr 29 06:42:26 2014 UTC +++ /branches/bleeding_edge/src/mips/macro-assembler-mips.cc Tue May 6 09:28:08 2014 UTC
@@ -4013,14 +4013,6 @@
 bool MacroAssembler::AllowThisStubCall(CodeStub* stub) {
   return has_frame_ || !stub->SometimesSetsUpAFrame();
 }
-
-
-void MacroAssembler::IllegalOperation(int num_arguments) {
-  if (num_arguments > 0) {
-    addiu(sp, sp, num_arguments * kPointerSize);
-  }
-  LoadRoot(v0, Heap::kUndefinedValueRootIndex);
-}


 void MacroAssembler::IndexFromHash(Register hash,
@@ -4177,10 +4169,7 @@
   // If the expected number of arguments of the runtime function is
   // constant, we check that the actual number of arguments match the
   // expectation.
-  if (f->nargs >= 0 && f->nargs != num_arguments) {
-    IllegalOperation(num_arguments);
-    return;
-  }
+  CHECK(f->nargs < 0 || f->nargs == num_arguments);

   // TODO(1236192): Most runtime routines don't need the number of
   // arguments passed in because it is constant. At some point we
=======================================
--- /branches/bleeding_edge/src/mips/macro-assembler-mips.h Tue Apr 29 06:42:26 2014 UTC +++ /branches/bleeding_edge/src/mips/macro-assembler-mips.h Tue May 6 09:28:08 2014 UTC
@@ -1048,10 +1048,6 @@
                    Handle<Code> success,
                    SmiCheckType smi_check_type);

-  // Generates code for reporting that an illegal operation has
-  // occurred.
-  void IllegalOperation(int num_arguments);
-

   // Load and check the instance type of an object for being a string.
   // Loads the type into the second argument register.
=======================================
--- /branches/bleeding_edge/src/regexp.js       Tue Apr 29 06:42:26 2014 UTC
+++ /branches/bleeding_edge/src/regexp.js       Tue May  6 09:28:08 2014 UTC
@@ -162,7 +162,6 @@
     i = 0;
   }

-  %_Log('regexp', 'regexp-exec,%0r,%1S,%2i', [this, string, lastIndex]);
   // matchIndices is either null or the lastMatchInfo array.
   var matchIndices = %_RegExpExec(this, string, i, lastMatchInfo);

@@ -206,7 +205,6 @@
       this.lastIndex = 0;
       return false;
     }
-    %_Log('regexp', 'regexp-exec,%0r,%1S,%2i', [this, string, lastIndex]);
     // matchIndices is either null or the lastMatchInfo array.
     var matchIndices = %_RegExpExec(this, string, i, lastMatchInfo);
     if (IS_NULL(matchIndices)) {
@@ -227,7 +225,6 @@
         %_StringCharCodeAt(regexp.source, 2) != 63) {  // '?'
       regexp = TrimRegExp(regexp);
     }
- %_Log('regexp', 'regexp-exec,%0r,%1S,%2i', [regexp, string, lastIndex]);
     // matchIndices is either null or the lastMatchInfo array.
     var matchIndices = %_RegExpExec(regexp, string, 0, lastMatchInfo);
     if (IS_NULL(matchIndices)) {
=======================================
--- /branches/bleeding_edge/src/runtime.cc      Mon May  5 21:44:36 2014 UTC
+++ /branches/bleeding_edge/src/runtime.cc      Tue May  6 09:28:08 2014 UTC
@@ -14799,19 +14799,6 @@
 #endif


-RUNTIME_FUNCTION(RuntimeHidden_Log) {
-  HandleScope handle_scope(isolate);
-  ASSERT(args.length() == 2);
-  CONVERT_ARG_HANDLE_CHECKED(String, format, 0);
-  CONVERT_ARG_HANDLE_CHECKED(JSArray, elms, 1);
-
-  SmartArrayPointer<char> format_chars = format->ToCString();
-  isolate->logger()->LogRuntime(
-      Vector<const char>(format_chars.get(), format->length()), elms);
-  return isolate->heap()->undefined_value();
-}
-
-
 RUNTIME_FUNCTION(Runtime_IS_VAR) {
   UNREACHABLE();  // implemented as macro in the parser
   return NULL;
=======================================
--- /branches/bleeding_edge/src/runtime.h       Fri May  2 21:29:15 2014 UTC
+++ /branches/bleeding_edge/src/runtime.h       Tue May  6 09:28:08 2014 UTC
@@ -544,7 +544,6 @@
   F(SubString, 3, 1) \
   F(StringCompare, 2, 1) \
   F(StringCharCodeAt, 2, 1) \
-  F(Log, 3, 1) \
   F(GetFromCache, 2, 1) \
   \
   /* Compilation */ \
@@ -657,7 +656,6 @@
F(DebugBreakInOptimizedCode, 0, 1) \ F(ClassOf, 1, 1) \ F(StringCharCodeAt, 2, 1) \ - F(Log, 3, 1) \ F(StringAdd, 2, 1) \ F(SubString, 3, 1) \ F(StringCompare, 2, 1) \
=======================================
--- /branches/bleeding_edge/src/string.js       Tue Apr 29 06:42:26 2014 UTC
+++ /branches/bleeding_edge/src/string.js       Tue May  6 09:28:08 2014 UTC
@@ -150,7 +150,6 @@
     var lastIndex = regexp.lastIndex;
     TO_INTEGER_FOR_SIDE_EFFECT(lastIndex);
     if (!regexp.global) return RegExpExecNoTests(regexp, subject, 0);
-    %_Log('regexp', 'regexp-match,%0S,%1r', [subject, regexp]);
     // lastMatchInfo is defined in regexp.js.
     var result = %StringMatch(subject, regexp, lastMatchInfo);
     if (result !== null) lastMatchInfoOverride = null;
@@ -221,7 +220,6 @@
     // value is discarded.
     var lastIndex = search.lastIndex;
     TO_INTEGER_FOR_SIDE_EFFECT(lastIndex);
-    %_Log('regexp', 'regexp-replace,%0r,%1S', [search, subject]);

     if (!IS_SPEC_FUNCTION(replace)) {
       replace = TO_STRING_INLINE(replace);
@@ -623,8 +621,6 @@
 var ArrayPushBuiltin = $Array.prototype.push;

 function StringSplitOnRegExp(subject, separator, limit, length) {
-  %_Log('regexp', 'regexp-split,%0S,%1r', [subject, separator]);
-
   if (length === 0) {
     if (DoRegExpExec(separator, subject, 0, 0) != null) {
       return [];
=======================================
--- /branches/bleeding_edge/src/x64/full-codegen-x64.cc Wed Apr 30 14:33:35 2014 UTC +++ /branches/bleeding_edge/src/x64/full-codegen-x64.cc Tue May 6 09:28:08 2014 UTC
@@ -3266,27 +3266,6 @@

   context()->Plug(rax);
 }
-
-
-void FullCodeGenerator::EmitLog(CallRuntime* expr) {
-  // Conditionally generate a log call.
-  // Args:
-  //   0 (literal string): The type of logging (corresponds to the flags).
-  //     This is used to determine whether or not to generate the log call.
-  //   1 (string): Format string.  Access the string at argument index 2
-  //     with '%2s' (see Logger::LogRuntime for all the formats).
-  //   2 (array): Arguments to the format string.
-  ZoneList<Expression*>* args = expr->arguments();
-  ASSERT_EQ(args->length(), 3);
-  if (CodeGenerator::ShouldGenerateLog(isolate(), args->at(0))) {
-    VisitForStackValue(args->at(1));
-    VisitForStackValue(args->at(2));
-    __ CallRuntime(Runtime::kHiddenLog, 2);
-  }
-  // Finally, we're expected to leave a value on the top of the stack.
-  __ LoadRoot(rax, Heap::kUndefinedValueRootIndex);
-  context()->Plug(rax);
-}


 void FullCodeGenerator::EmitSubString(CallRuntime* expr) {
=======================================
--- /branches/bleeding_edge/src/x64/macro-assembler-x64.cc Wed Apr 30 09:50:58 2014 UTC +++ /branches/bleeding_edge/src/x64/macro-assembler-x64.cc Tue May 6 09:28:08 2014 UTC
@@ -540,14 +540,6 @@
 bool MacroAssembler::AllowThisStubCall(CodeStub* stub) {
   return has_frame_ || !stub->SometimesSetsUpAFrame();
 }
-
-
-void MacroAssembler::IllegalOperation(int num_arguments) {
-  if (num_arguments > 0) {
-    addp(rsp, Immediate(num_arguments * kPointerSize));
-  }
-  LoadRoot(rax, Heap::kUndefinedValueRootIndex);
-}


 void MacroAssembler::IndexFromHash(Register hash, Register index) {
@@ -575,10 +567,7 @@
   // If the expected number of arguments of the runtime function is
   // constant, we check that the actual number of arguments match the
   // expectation.
-  if (f->nargs >= 0 && f->nargs != num_arguments) {
-    IllegalOperation(num_arguments);
-    return;
-  }
+  CHECK(f->nargs < 0 || f->nargs == num_arguments);

   // TODO(1236192): Most runtime routines don't need the number of
   // arguments passed in because it is constant. At some point we
=======================================
--- /branches/bleeding_edge/src/x64/macro-assembler-x64.h Wed Apr 30 09:23:41 2014 UTC +++ /branches/bleeding_edge/src/x64/macro-assembler-x64.h Tue May 6 09:28:08 2014 UTC
@@ -1205,10 +1205,6 @@
                                Label* miss,
                                bool miss_on_bound_function = false);

-  // Generates code for reporting that an illegal operation has
-  // occurred.
-  void IllegalOperation(int num_arguments);
-
   // Picks out an array index from the hash field.
   // Register use:
   //   hash - holds the index's hash. Clobbered.

--
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
--- You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to