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_MIPS | 5 #if V8_TARGET_ARCH_MIPS |
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 3124 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3135 | 3135 |
3136 __ JumpIfSmi(v0, if_false); | 3136 __ JumpIfSmi(v0, if_false); |
3137 __ GetObjectType(v0, a1, a1); | 3137 __ GetObjectType(v0, a1, a1); |
3138 PrepareForBailoutBeforeSplit(expr, true, if_true, if_false); | 3138 PrepareForBailoutBeforeSplit(expr, true, if_true, if_false); |
3139 Split(eq, a1, Operand(SIMD128_VALUE_TYPE), if_true, if_false, fall_through); | 3139 Split(eq, a1, Operand(SIMD128_VALUE_TYPE), if_true, if_false, fall_through); |
3140 | 3140 |
3141 context()->Plug(if_true, if_false); | 3141 context()->Plug(if_true, if_false); |
3142 } | 3142 } |
3143 | 3143 |
3144 | 3144 |
3145 void FullCodeGenerator::EmitIsFunction(CallRuntime* expr) { | |
3146 ZoneList<Expression*>* args = expr->arguments(); | |
3147 DCHECK(args->length() == 1); | |
3148 | |
3149 VisitForAccumulatorValue(args->at(0)); | |
3150 | |
3151 Label materialize_true, materialize_false; | |
3152 Label* if_true = NULL; | |
3153 Label* if_false = NULL; | |
3154 Label* fall_through = NULL; | |
3155 context()->PrepareTest(&materialize_true, &materialize_false, | |
3156 &if_true, &if_false, &fall_through); | |
3157 | |
3158 __ JumpIfSmi(v0, if_false); | |
3159 __ GetObjectType(v0, a1, a2); | |
3160 PrepareForBailoutBeforeSplit(expr, true, if_true, if_false); | |
3161 __ Branch(if_true, hs, a2, Operand(FIRST_FUNCTION_TYPE)); | |
3162 __ Branch(if_false); | |
3163 | |
3164 context()->Plug(if_true, if_false); | |
3165 } | |
3166 | |
3167 | |
3168 void FullCodeGenerator::EmitIsMinusZero(CallRuntime* expr) { | 3145 void FullCodeGenerator::EmitIsMinusZero(CallRuntime* expr) { |
3169 ZoneList<Expression*>* args = expr->arguments(); | 3146 ZoneList<Expression*>* args = expr->arguments(); |
3170 DCHECK(args->length() == 1); | 3147 DCHECK(args->length() == 1); |
3171 | 3148 |
3172 VisitForAccumulatorValue(args->at(0)); | 3149 VisitForAccumulatorValue(args->at(0)); |
3173 | 3150 |
3174 Label materialize_true, materialize_false; | 3151 Label materialize_true, materialize_false; |
3175 Label* if_true = NULL; | 3152 Label* if_true = NULL; |
3176 Label* if_false = NULL; | 3153 Label* if_false = NULL; |
3177 Label* fall_through = NULL; | 3154 Label* fall_through = NULL; |
(...skipping 1640 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4818 reinterpret_cast<uint32_t>( | 4795 reinterpret_cast<uint32_t>( |
4819 isolate->builtins()->OsrAfterStackCheck()->entry())); | 4796 isolate->builtins()->OsrAfterStackCheck()->entry())); |
4820 return OSR_AFTER_STACK_CHECK; | 4797 return OSR_AFTER_STACK_CHECK; |
4821 } | 4798 } |
4822 | 4799 |
4823 | 4800 |
4824 } // namespace internal | 4801 } // namespace internal |
4825 } // namespace v8 | 4802 } // namespace v8 |
4826 | 4803 |
4827 #endif // V8_TARGET_ARCH_MIPS | 4804 #endif // V8_TARGET_ARCH_MIPS |
OLD | NEW |