| OLD | NEW |
| 1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
| 2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
| 3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
| 4 // met: | 4 // met: |
| 5 // | 5 // |
| 6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
| 7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
| 8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
| 9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
| 10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
| (...skipping 3592 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3603 generator.GenerateSlow(masm_, call_helper); | 3603 generator.GenerateSlow(masm_, call_helper); |
| 3604 | 3604 |
| 3605 __ bind(&done); | 3605 __ bind(&done); |
| 3606 context()->Plug(result); | 3606 context()->Plug(result); |
| 3607 } | 3607 } |
| 3608 | 3608 |
| 3609 | 3609 |
| 3610 void FullCodeGenerator::EmitStringAdd(CallRuntime* expr) { | 3610 void FullCodeGenerator::EmitStringAdd(CallRuntime* expr) { |
| 3611 ZoneList<Expression*>* args = expr->arguments(); | 3611 ZoneList<Expression*>* args = expr->arguments(); |
| 3612 ASSERT_EQ(2, args->length()); | 3612 ASSERT_EQ(2, args->length()); |
| 3613 VisitForStackValue(args->at(0)); |
| 3614 VisitForAccumulatorValue(args->at(1)); |
| 3613 | 3615 |
| 3614 if (FLAG_new_string_add) { | 3616 __ pop(rdx); |
| 3615 VisitForStackValue(args->at(0)); | 3617 StringAddStub stub(STRING_ADD_CHECK_BOTH, NOT_TENURED); |
| 3616 VisitForAccumulatorValue(args->at(1)); | 3618 __ CallStub(&stub); |
| 3617 | |
| 3618 __ pop(rdx); | |
| 3619 NewStringAddStub stub(STRING_ADD_CHECK_BOTH, NOT_TENURED); | |
| 3620 __ CallStub(&stub); | |
| 3621 } else { | |
| 3622 VisitForStackValue(args->at(0)); | |
| 3623 VisitForStackValue(args->at(1)); | |
| 3624 | |
| 3625 StringAddStub stub(STRING_ADD_CHECK_BOTH); | |
| 3626 __ CallStub(&stub); | |
| 3627 } | |
| 3628 context()->Plug(rax); | 3619 context()->Plug(rax); |
| 3629 } | 3620 } |
| 3630 | 3621 |
| 3631 | 3622 |
| 3632 void FullCodeGenerator::EmitStringCompare(CallRuntime* expr) { | 3623 void FullCodeGenerator::EmitStringCompare(CallRuntime* expr) { |
| 3633 ZoneList<Expression*>* args = expr->arguments(); | 3624 ZoneList<Expression*>* args = expr->arguments(); |
| 3634 ASSERT_EQ(2, args->length()); | 3625 ASSERT_EQ(2, args->length()); |
| 3635 | 3626 |
| 3636 VisitForStackValue(args->at(0)); | 3627 VisitForStackValue(args->at(0)); |
| 3637 VisitForStackValue(args->at(1)); | 3628 VisitForStackValue(args->at(1)); |
| (...skipping 1262 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4900 | 4891 |
| 4901 ASSERT_EQ(isolate->builtins()->OsrAfterStackCheck()->entry(), | 4892 ASSERT_EQ(isolate->builtins()->OsrAfterStackCheck()->entry(), |
| 4902 Assembler::target_address_at(call_target_address)); | 4893 Assembler::target_address_at(call_target_address)); |
| 4903 return OSR_AFTER_STACK_CHECK; | 4894 return OSR_AFTER_STACK_CHECK; |
| 4904 } | 4895 } |
| 4905 | 4896 |
| 4906 | 4897 |
| 4907 } } // namespace v8::internal | 4898 } } // namespace v8::internal |
| 4908 | 4899 |
| 4909 #endif // V8_TARGET_ARCH_X64 | 4900 #endif // V8_TARGET_ARCH_X64 |
| OLD | NEW |