OLD | NEW |
1 // Copyright 2011 the V8 project authors. All rights reserved. | 1 // Copyright 2011 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 1196 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1207 // See comment at call site. | 1207 // See comment at call site. |
1208 static void EmitStrictTwoHeapObjectCompare(MacroAssembler* masm, | 1208 static void EmitStrictTwoHeapObjectCompare(MacroAssembler* masm, |
1209 Register lhs, | 1209 Register lhs, |
1210 Register rhs) { | 1210 Register rhs) { |
1211 ASSERT((lhs.is(r0) && rhs.is(r1)) || | 1211 ASSERT((lhs.is(r0) && rhs.is(r1)) || |
1212 (lhs.is(r1) && rhs.is(r0))); | 1212 (lhs.is(r1) && rhs.is(r0))); |
1213 | 1213 |
1214 // If either operand is a JS object or an oddball value, then they are | 1214 // If either operand is a JS object or an oddball value, then they are |
1215 // not equal since their pointers are different. | 1215 // not equal since their pointers are different. |
1216 // There is no test for undetectability in strict equality. | 1216 // There is no test for undetectability in strict equality. |
1217 STATIC_ASSERT(LAST_TYPE == LAST_CALLABLE_SPEC_OBJECT_TYPE); | 1217 STATIC_ASSERT(LAST_TYPE == LAST_SPEC_OBJECT_TYPE); |
1218 Label first_non_object; | 1218 Label first_non_object; |
1219 // Get the type of the first operand into r2 and compare it with | 1219 // Get the type of the first operand into r2 and compare it with |
1220 // FIRST_SPEC_OBJECT_TYPE. | 1220 // FIRST_SPEC_OBJECT_TYPE. |
1221 __ CompareObjectType(rhs, r2, r2, FIRST_SPEC_OBJECT_TYPE); | 1221 __ CompareObjectType(rhs, r2, r2, FIRST_SPEC_OBJECT_TYPE); |
1222 __ b(lt, &first_non_object); | 1222 __ b(lt, &first_non_object); |
1223 | 1223 |
1224 // Return non-zero (r0 is not zero) | 1224 // Return non-zero (r0 is not zero) |
1225 Label return_not_equal; | 1225 Label return_not_equal; |
1226 __ bind(&return_not_equal); | 1226 __ bind(&return_not_equal); |
1227 __ Ret(); | 1227 __ Ret(); |
(...skipping 5472 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
6700 __ mov(result, Operand::Zero()); | 6700 __ mov(result, Operand::Zero()); |
6701 __ Ret(); | 6701 __ Ret(); |
6702 } | 6702 } |
6703 | 6703 |
6704 | 6704 |
6705 #undef __ | 6705 #undef __ |
6706 | 6706 |
6707 } } // namespace v8::internal | 6707 } } // namespace v8::internal |
6708 | 6708 |
6709 #endif // V8_TARGET_ARCH_ARM | 6709 #endif // V8_TARGET_ARCH_ARM |
OLD | NEW |