| 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 #if V8_TARGET_ARCH_MIPS64 | 5 #if V8_TARGET_ARCH_MIPS64 |
| 6 | 6 |
| 7 // Note on Mips implementation: | 7 // Note on Mips implementation: |
| 8 // | 8 // |
| 9 // The result_register() for mips is the 'v0' register, which is defined | 9 // The result_register() for mips is the 'v0' register, which is defined |
| 10 // by the ABI to contain function return values. However, the first | 10 // by the ABI to contain function return values. However, the first |
| (...skipping 3103 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3114 | 3114 |
| 3115 __ JumpIfSmi(v0, if_false); | 3115 __ JumpIfSmi(v0, if_false); |
| 3116 __ GetObjectType(v0, a1, a1); | 3116 __ GetObjectType(v0, a1, a1); |
| 3117 PrepareForBailoutBeforeSplit(expr, true, if_true, if_false); | 3117 PrepareForBailoutBeforeSplit(expr, true, if_true, if_false); |
| 3118 Split(eq, a1, Operand(JS_PROXY_TYPE), if_true, if_false, fall_through); | 3118 Split(eq, a1, Operand(JS_PROXY_TYPE), if_true, if_false, fall_through); |
| 3119 | 3119 |
| 3120 context()->Plug(if_true, if_false); | 3120 context()->Plug(if_true, if_false); |
| 3121 } | 3121 } |
| 3122 | 3122 |
| 3123 | 3123 |
| 3124 void FullCodeGenerator::EmitObjectEquals(CallRuntime* expr) { | |
| 3125 ZoneList<Expression*>* args = expr->arguments(); | |
| 3126 DCHECK(args->length() == 2); | |
| 3127 | |
| 3128 // Load the two objects into registers and perform the comparison. | |
| 3129 VisitForStackValue(args->at(0)); | |
| 3130 VisitForAccumulatorValue(args->at(1)); | |
| 3131 | |
| 3132 Label materialize_true, materialize_false; | |
| 3133 Label* if_true = NULL; | |
| 3134 Label* if_false = NULL; | |
| 3135 Label* fall_through = NULL; | |
| 3136 context()->PrepareTest(&materialize_true, &materialize_false, | |
| 3137 &if_true, &if_false, &fall_through); | |
| 3138 | |
| 3139 __ pop(a1); | |
| 3140 PrepareForBailoutBeforeSplit(expr, true, if_true, if_false); | |
| 3141 Split(eq, v0, Operand(a1), if_true, if_false, fall_through); | |
| 3142 | |
| 3143 context()->Plug(if_true, if_false); | |
| 3144 } | |
| 3145 | |
| 3146 | |
| 3147 void FullCodeGenerator::EmitClassOf(CallRuntime* expr) { | 3124 void FullCodeGenerator::EmitClassOf(CallRuntime* expr) { |
| 3148 ZoneList<Expression*>* args = expr->arguments(); | 3125 ZoneList<Expression*>* args = expr->arguments(); |
| 3149 DCHECK(args->length() == 1); | 3126 DCHECK(args->length() == 1); |
| 3150 Label done, null, function, non_function_constructor; | 3127 Label done, null, function, non_function_constructor; |
| 3151 | 3128 |
| 3152 VisitForAccumulatorValue(args->at(0)); | 3129 VisitForAccumulatorValue(args->at(0)); |
| 3153 | 3130 |
| 3154 // If the object is not a JSReceiver, we return null. | 3131 // If the object is not a JSReceiver, we return null. |
| 3155 __ JumpIfSmi(v0, &null); | 3132 __ JumpIfSmi(v0, &null); |
| 3156 STATIC_ASSERT(LAST_JS_RECEIVER_TYPE == LAST_TYPE); | 3133 STATIC_ASSERT(LAST_JS_RECEIVER_TYPE == LAST_TYPE); |
| (...skipping 1475 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4632 reinterpret_cast<uint64_t>( | 4609 reinterpret_cast<uint64_t>( |
| 4633 isolate->builtins()->OsrAfterStackCheck()->entry())); | 4610 isolate->builtins()->OsrAfterStackCheck()->entry())); |
| 4634 return OSR_AFTER_STACK_CHECK; | 4611 return OSR_AFTER_STACK_CHECK; |
| 4635 } | 4612 } |
| 4636 | 4613 |
| 4637 | 4614 |
| 4638 } // namespace internal | 4615 } // namespace internal |
| 4639 } // namespace v8 | 4616 } // namespace v8 |
| 4640 | 4617 |
| 4641 #endif // V8_TARGET_ARCH_MIPS64 | 4618 #endif // V8_TARGET_ARCH_MIPS64 |
| OLD | NEW |