| 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 1960 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1971 | 1971 |
| 1972 __ JumpIfSmi(v0, if_false); | 1972 __ JumpIfSmi(v0, if_false); |
| 1973 __ GetObjectType(v0, a1, a1); | 1973 __ GetObjectType(v0, a1, a1); |
| 1974 PrepareForBailoutBeforeSplit(expr, true, if_true, if_false); | 1974 PrepareForBailoutBeforeSplit(expr, true, if_true, if_false); |
| 1975 Split(eq, a1, Operand(JS_TYPED_ARRAY_TYPE), if_true, if_false, fall_through); | 1975 Split(eq, a1, Operand(JS_TYPED_ARRAY_TYPE), if_true, if_false, fall_through); |
| 1976 | 1976 |
| 1977 context()->Plug(if_true, if_false); | 1977 context()->Plug(if_true, if_false); |
| 1978 } | 1978 } |
| 1979 | 1979 |
| 1980 | 1980 |
| 1981 void FullCodeGenerator::EmitIsRegExp(CallRuntime* expr) { | |
| 1982 ZoneList<Expression*>* args = expr->arguments(); | |
| 1983 DCHECK(args->length() == 1); | |
| 1984 | |
| 1985 VisitForAccumulatorValue(args->at(0)); | |
| 1986 | |
| 1987 Label materialize_true, materialize_false; | |
| 1988 Label* if_true = NULL; | |
| 1989 Label* if_false = NULL; | |
| 1990 Label* fall_through = NULL; | |
| 1991 context()->PrepareTest(&materialize_true, &materialize_false, | |
| 1992 &if_true, &if_false, &fall_through); | |
| 1993 | |
| 1994 __ JumpIfSmi(v0, if_false); | |
| 1995 __ GetObjectType(v0, a1, a1); | |
| 1996 PrepareForBailoutBeforeSplit(expr, true, if_true, if_false); | |
| 1997 Split(eq, a1, Operand(JS_REGEXP_TYPE), if_true, if_false, fall_through); | |
| 1998 | |
| 1999 context()->Plug(if_true, if_false); | |
| 2000 } | |
| 2001 | |
| 2002 | |
| 2003 void FullCodeGenerator::EmitIsJSProxy(CallRuntime* expr) { | 1981 void FullCodeGenerator::EmitIsJSProxy(CallRuntime* expr) { |
| 2004 ZoneList<Expression*>* args = expr->arguments(); | 1982 ZoneList<Expression*>* args = expr->arguments(); |
| 2005 DCHECK(args->length() == 1); | 1983 DCHECK(args->length() == 1); |
| 2006 | 1984 |
| 2007 VisitForAccumulatorValue(args->at(0)); | 1985 VisitForAccumulatorValue(args->at(0)); |
| 2008 | 1986 |
| 2009 Label materialize_true, materialize_false; | 1987 Label materialize_true, materialize_false; |
| 2010 Label* if_true = NULL; | 1988 Label* if_true = NULL; |
| 2011 Label* if_false = NULL; | 1989 Label* if_false = NULL; |
| 2012 Label* fall_through = NULL; | 1990 Label* fall_through = NULL; |
| (...skipping 801 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2814 reinterpret_cast<uint32_t>( | 2792 reinterpret_cast<uint32_t>( |
| 2815 isolate->builtins()->OnStackReplacement()->entry())); | 2793 isolate->builtins()->OnStackReplacement()->entry())); |
| 2816 return ON_STACK_REPLACEMENT; | 2794 return ON_STACK_REPLACEMENT; |
| 2817 } | 2795 } |
| 2818 | 2796 |
| 2819 | 2797 |
| 2820 } // namespace internal | 2798 } // namespace internal |
| 2821 } // namespace v8 | 2799 } // namespace v8 |
| 2822 | 2800 |
| 2823 #endif // V8_TARGET_ARCH_MIPS | 2801 #endif // V8_TARGET_ARCH_MIPS |
| OLD | NEW |