| OLD | NEW |
| 1 // Copyright 2010 the V8 project authors. All rights reserved. | 1 // Copyright 2010 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 1973 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1984 __ cmpq(rbx, Immediate(FIRST_JS_OBJECT_TYPE)); | 1984 __ cmpq(rbx, Immediate(FIRST_JS_OBJECT_TYPE)); |
| 1985 __ j(below, if_false); | 1985 __ j(below, if_false); |
| 1986 __ cmpq(rbx, Immediate(LAST_JS_OBJECT_TYPE)); | 1986 __ cmpq(rbx, Immediate(LAST_JS_OBJECT_TYPE)); |
| 1987 __ j(below_equal, if_true); | 1987 __ j(below_equal, if_true); |
| 1988 __ jmp(if_false); | 1988 __ jmp(if_false); |
| 1989 | 1989 |
| 1990 Apply(context_, if_true, if_false); | 1990 Apply(context_, if_true, if_false); |
| 1991 } | 1991 } |
| 1992 | 1992 |
| 1993 | 1993 |
| 1994 void FullCodeGenerator::EmitIsSpecObject(ZoneList<Expression*>* args) { |
| 1995 ASSERT(args->length() == 1); |
| 1996 |
| 1997 VisitForValue(args->at(0), kAccumulator); |
| 1998 |
| 1999 Label materialize_true, materialize_false; |
| 2000 Label* if_true = NULL; |
| 2001 Label* if_false = NULL; |
| 2002 PrepareTest(&materialize_true, &materialize_false, &if_true, &if_false); |
| 2003 |
| 2004 __ JumpIfSmi(rax, if_false); |
| 2005 __ CmpObjectType(rax, FIRST_JS_OBJECT_TYPE, rbx); |
| 2006 __ j(above_equal, if_true); |
| 2007 __ jmp(if_false); |
| 2008 |
| 2009 Apply(context_, if_true, if_false); |
| 2010 } |
| 2011 |
| 2012 |
| 1994 void FullCodeGenerator::EmitIsUndetectableObject(ZoneList<Expression*>* args) { | 2013 void FullCodeGenerator::EmitIsUndetectableObject(ZoneList<Expression*>* args) { |
| 1995 ASSERT(args->length() == 1); | 2014 ASSERT(args->length() == 1); |
| 1996 | 2015 |
| 1997 VisitForValue(args->at(0), kAccumulator); | 2016 VisitForValue(args->at(0), kAccumulator); |
| 1998 | 2017 |
| 1999 Label materialize_true, materialize_false; | 2018 Label materialize_true, materialize_false; |
| 2000 Label* if_true = NULL; | 2019 Label* if_true = NULL; |
| 2001 Label* if_false = NULL; | 2020 Label* if_false = NULL; |
| 2002 PrepareTest(&materialize_true, &materialize_false, &if_true, &if_false); | 2021 PrepareTest(&materialize_true, &materialize_false, &if_true, &if_false); |
| 2003 | 2022 |
| (...skipping 1238 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3242 __ ret(0); | 3261 __ ret(0); |
| 3243 } | 3262 } |
| 3244 | 3263 |
| 3245 | 3264 |
| 3246 #undef __ | 3265 #undef __ |
| 3247 | 3266 |
| 3248 | 3267 |
| 3249 } } // namespace v8::internal | 3268 } } // namespace v8::internal |
| 3250 | 3269 |
| 3251 #endif // V8_TARGET_ARCH_X64 | 3270 #endif // V8_TARGET_ARCH_X64 |
| OLD | NEW |