| OLD | NEW |
| 1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "src/v8.h" | 5 #include "src/v8.h" |
| 6 | 6 |
| 7 #if V8_TARGET_ARCH_X64 | 7 #if V8_TARGET_ARCH_X64 |
| 8 | 8 |
| 9 #include "src/code-factory.h" | 9 #include "src/code-factory.h" |
| 10 #include "src/code-stubs.h" | 10 #include "src/code-stubs.h" |
| (...skipping 3977 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3988 __ LoadRoot(result, Heap::kNanValueRootIndex); | 3988 __ LoadRoot(result, Heap::kNanValueRootIndex); |
| 3989 __ jmp(&done); | 3989 __ jmp(&done); |
| 3990 | 3990 |
| 3991 __ bind(&need_conversion); | 3991 __ bind(&need_conversion); |
| 3992 // Move the undefined value into the result register, which will | 3992 // Move the undefined value into the result register, which will |
| 3993 // trigger conversion. | 3993 // trigger conversion. |
| 3994 __ LoadRoot(result, Heap::kUndefinedValueRootIndex); | 3994 __ LoadRoot(result, Heap::kUndefinedValueRootIndex); |
| 3995 __ jmp(&done); | 3995 __ jmp(&done); |
| 3996 | 3996 |
| 3997 NopRuntimeCallHelper call_helper; | 3997 NopRuntimeCallHelper call_helper; |
| 3998 generator.GenerateSlow(masm_, call_helper); | 3998 generator.GenerateSlow(masm_, NOT_PART_OF_IC_HANDLER, call_helper); |
| 3999 | 3999 |
| 4000 __ bind(&done); | 4000 __ bind(&done); |
| 4001 context()->Plug(result); | 4001 context()->Plug(result); |
| 4002 } | 4002 } |
| 4003 | 4003 |
| 4004 | 4004 |
| 4005 void FullCodeGenerator::EmitStringCharAt(CallRuntime* expr) { | 4005 void FullCodeGenerator::EmitStringCharAt(CallRuntime* expr) { |
| 4006 ZoneList<Expression*>* args = expr->arguments(); | 4006 ZoneList<Expression*>* args = expr->arguments(); |
| 4007 DCHECK(args->length() == 2); | 4007 DCHECK(args->length() == 2); |
| 4008 | 4008 |
| (...skipping 27 matching lines...) Expand all Loading... |
| 4036 __ LoadRoot(result, Heap::kempty_stringRootIndex); | 4036 __ LoadRoot(result, Heap::kempty_stringRootIndex); |
| 4037 __ jmp(&done); | 4037 __ jmp(&done); |
| 4038 | 4038 |
| 4039 __ bind(&need_conversion); | 4039 __ bind(&need_conversion); |
| 4040 // Move smi zero into the result register, which will trigger | 4040 // Move smi zero into the result register, which will trigger |
| 4041 // conversion. | 4041 // conversion. |
| 4042 __ Move(result, Smi::FromInt(0)); | 4042 __ Move(result, Smi::FromInt(0)); |
| 4043 __ jmp(&done); | 4043 __ jmp(&done); |
| 4044 | 4044 |
| 4045 NopRuntimeCallHelper call_helper; | 4045 NopRuntimeCallHelper call_helper; |
| 4046 generator.GenerateSlow(masm_, call_helper); | 4046 generator.GenerateSlow(masm_, NOT_PART_OF_IC_HANDLER, call_helper); |
| 4047 | 4047 |
| 4048 __ bind(&done); | 4048 __ bind(&done); |
| 4049 context()->Plug(result); | 4049 context()->Plug(result); |
| 4050 } | 4050 } |
| 4051 | 4051 |
| 4052 | 4052 |
| 4053 void FullCodeGenerator::EmitStringAdd(CallRuntime* expr) { | 4053 void FullCodeGenerator::EmitStringAdd(CallRuntime* expr) { |
| 4054 ZoneList<Expression*>* args = expr->arguments(); | 4054 ZoneList<Expression*>* args = expr->arguments(); |
| 4055 DCHECK_EQ(2, args->length()); | 4055 DCHECK_EQ(2, args->length()); |
| 4056 VisitForStackValue(args->at(0)); | 4056 VisitForStackValue(args->at(0)); |
| (...skipping 1343 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 5400 DCHECK_EQ(isolate->builtins()->OsrAfterStackCheck()->entry(), | 5400 DCHECK_EQ(isolate->builtins()->OsrAfterStackCheck()->entry(), |
| 5401 Assembler::target_address_at(call_target_address, | 5401 Assembler::target_address_at(call_target_address, |
| 5402 unoptimized_code)); | 5402 unoptimized_code)); |
| 5403 return OSR_AFTER_STACK_CHECK; | 5403 return OSR_AFTER_STACK_CHECK; |
| 5404 } | 5404 } |
| 5405 | 5405 |
| 5406 | 5406 |
| 5407 } } // namespace v8::internal | 5407 } } // namespace v8::internal |
| 5408 | 5408 |
| 5409 #endif // V8_TARGET_ARCH_X64 | 5409 #endif // V8_TARGET_ARCH_X64 |
| OLD | NEW |