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

Unified Diff: src/ia32/code-stubs-ia32.cc

Issue 3290012: Avoid pushing arguments twice in GenericBinaryOpStub.... (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: '' Created 10 years, 3 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 | « no previous file | test/mjsunit/regress/regress-push-args-twice.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/ia32/code-stubs-ia32.cc
===================================================================
--- src/ia32/code-stubs-ia32.cc (revision 5415)
+++ src/ia32/code-stubs-ia32.cc (working copy)
@@ -1044,12 +1044,13 @@
StringAddStub string_add_left_stub(NO_STRING_CHECK_LEFT_IN_STUB);
__ TailCallStub(&string_add_left_stub);
+ Label call_runtime_with_args;
// Left operand is not a string, test right.
__ bind(&lhs_not_string);
__ test(rhs, Immediate(kSmiTagMask));
- __ j(zero, &call_runtime);
+ __ j(zero, &call_runtime_with_args);
__ CmpObjectType(rhs, FIRST_NONSTRING_TYPE, ecx);
- __ j(above_equal, &call_runtime);
+ __ j(above_equal, &call_runtime_with_args);
StringAddStub string_add_right_stub(NO_STRING_CHECK_RIGHT_IN_STUB);
__ TailCallStub(&string_add_right_stub);
@@ -1059,6 +1060,7 @@
if (HasArgsInRegisters()) {
GenerateRegisterArgsPush(masm);
}
+ __ bind(&call_runtime_with_args);
__ InvokeBuiltin(Builtins::ADD, JUMP_FUNCTION);
break;
}
« no previous file with comments | « no previous file | test/mjsunit/regress/regress-push-args-twice.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698