Revision: 24950
Author:   [email protected]
Date:     Tue Oct 28 15:43:31 2014 UTC
Log:      MIPS: Use shared function info for eval cache key.

Port r24927 (244472a)

BUG=
[email protected]

Review URL: https://codereview.chromium.org/681303002
https://code.google.com/p/v8/source/detail?r=24950

Modified:
 /branches/bleeding_edge/src/mips/full-codegen-mips.cc
 /branches/bleeding_edge/src/mips64/full-codegen-mips64.cc

=======================================
--- /branches/bleeding_edge/src/mips/full-codegen-mips.cc Sun Oct 26 10:24:49 2014 UTC +++ /branches/bleeding_edge/src/mips/full-codegen-mips.cc Tue Oct 28 15:43:31 2014 UTC
@@ -2919,12 +2919,15 @@


 void FullCodeGenerator::EmitResolvePossiblyDirectEval(int arg_count) {
-  // t2: copy of the first argument or undefined if it doesn't exist.
+  // t3: copy of the first argument or undefined if it doesn't exist.
   if (arg_count > 0) {
-    __ lw(t2, MemOperand(sp, arg_count * kPointerSize));
+    __ lw(t3, MemOperand(sp, arg_count * kPointerSize));
   } else {
-    __ LoadRoot(t2, Heap::kUndefinedValueRootIndex);
+    __ LoadRoot(t3, Heap::kUndefinedValueRootIndex);
   }
+
+  // t2: the receiver of the enclosing function.
+  __ lw(t2, MemOperand(fp, JavaScriptFrameConstants::kFunctionOffset));

   // t1: the receiver of the enclosing function.
   int receiver_offset = 2 + info_->scope()->num_parameters();
@@ -2937,8 +2940,9 @@
   __ li(a1, Operand(Smi::FromInt(scope()->start_position())));

   // Do the runtime call.
+  __ Push(t3);
   __ Push(t2, t1, t0, a1);
-  __ CallRuntime(Runtime::kResolvePossiblyDirectEval, 5);
+  __ CallRuntime(Runtime::kResolvePossiblyDirectEval, 6);
 }


=======================================
--- /branches/bleeding_edge/src/mips64/full-codegen-mips64.cc Sun Oct 26 22:43:17 2014 UTC +++ /branches/bleeding_edge/src/mips64/full-codegen-mips64.cc Tue Oct 28 15:43:31 2014 UTC
@@ -2918,12 +2918,15 @@


 void FullCodeGenerator::EmitResolvePossiblyDirectEval(int arg_count) {
-  // a6: copy of the first argument or undefined if it doesn't exist.
+  // a7: copy of the first argument or undefined if it doesn't exist.
   if (arg_count > 0) {
-    __ ld(a6, MemOperand(sp, arg_count * kPointerSize));
+    __ ld(a7, MemOperand(sp, arg_count * kPointerSize));
   } else {
-    __ LoadRoot(a6, Heap::kUndefinedValueRootIndex);
+    __ LoadRoot(a7, Heap::kUndefinedValueRootIndex);
   }
+
+  // a6: the receiver of the enclosing function.
+  __ ld(a6, MemOperand(fp, JavaScriptFrameConstants::kFunctionOffset));

   // a5: the receiver of the enclosing function.
   int receiver_offset = 2 + info_->scope()->num_parameters();
@@ -2936,8 +2939,9 @@
   __ li(a1, Operand(Smi::FromInt(scope()->start_position())));

   // Do the runtime call.
+  __ Push(a7);
   __ Push(a6, a5, a4, a1);
-  __ CallRuntime(Runtime::kResolvePossiblyDirectEval, 5);
+  __ CallRuntime(Runtime::kResolvePossiblyDirectEval, 6);
 }


--
--
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