OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 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 6895 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
6906 // types loaded in tmp1 and tmp2. | 6906 // types loaded in tmp1 and tmp2. |
6907 STATIC_ASSERT(kInternalizedTag != 0); | 6907 STATIC_ASSERT(kInternalizedTag != 0); |
6908 __ mov(tmp1, FieldOperand(left, HeapObject::kMapOffset)); | 6908 __ mov(tmp1, FieldOperand(left, HeapObject::kMapOffset)); |
6909 __ mov(tmp2, FieldOperand(right, HeapObject::kMapOffset)); | 6909 __ mov(tmp2, FieldOperand(right, HeapObject::kMapOffset)); |
6910 __ movzx_b(tmp1, FieldOperand(tmp1, Map::kInstanceTypeOffset)); | 6910 __ movzx_b(tmp1, FieldOperand(tmp1, Map::kInstanceTypeOffset)); |
6911 __ movzx_b(tmp2, FieldOperand(tmp2, Map::kInstanceTypeOffset)); | 6911 __ movzx_b(tmp2, FieldOperand(tmp2, Map::kInstanceTypeOffset)); |
6912 | 6912 |
6913 Label succeed1; | 6913 Label succeed1; |
6914 __ test(tmp1, Immediate(kIsInternalizedMask)); | 6914 __ test(tmp1, Immediate(kIsInternalizedMask)); |
6915 __ j(not_zero, &succeed1); | 6915 __ j(not_zero, &succeed1); |
6916 __ cmpb(tmp1, static_cast<int8_t>(SYMBOL_TYPE)); | 6916 __ cmpb(tmp1, static_cast<uint8_t>(SYMBOL_TYPE)); |
6917 __ j(not_equal, &miss); | 6917 __ j(not_equal, &miss); |
6918 __ bind(&succeed1); | 6918 __ bind(&succeed1); |
6919 | 6919 |
6920 Label succeed2; | 6920 Label succeed2; |
6921 __ test(tmp2, Immediate(kIsInternalizedMask)); | 6921 __ test(tmp2, Immediate(kIsInternalizedMask)); |
6922 __ j(not_zero, &succeed2); | 6922 __ j(not_zero, &succeed2); |
6923 __ cmpb(tmp2, static_cast<int8_t>(SYMBOL_TYPE)); | 6923 __ cmpb(tmp2, static_cast<uint8_t>(SYMBOL_TYPE)); |
6924 __ j(not_equal, &miss); | 6924 __ j(not_equal, &miss); |
6925 __ bind(&succeed2); | 6925 __ bind(&succeed2); |
6926 | 6926 |
6927 // Unique names are compared by identity. | 6927 // Unique names are compared by identity. |
6928 Label done; | 6928 Label done; |
6929 __ cmp(left, right); | 6929 __ cmp(left, right); |
6930 // Make sure eax is non-zero. At this point input operands are | 6930 // Make sure eax is non-zero. At this point input operands are |
6931 // guaranteed to be non-zero. | 6931 // guaranteed to be non-zero. |
6932 ASSERT(right.is(eax)); | 6932 ASSERT(right.is(eax)); |
6933 __ j(not_equal, &done, Label::kNear); | 6933 __ j(not_equal, &done, Label::kNear); |
(...skipping 804 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
7738 // Restore ecx. | 7738 // Restore ecx. |
7739 __ pop(ecx); | 7739 __ pop(ecx); |
7740 __ ret(0); | 7740 __ ret(0); |
7741 } | 7741 } |
7742 | 7742 |
7743 #undef __ | 7743 #undef __ |
7744 | 7744 |
7745 } } // namespace v8::internal | 7745 } } // namespace v8::internal |
7746 | 7746 |
7747 #endif // V8_TARGET_ARCH_IA32 | 7747 #endif // V8_TARGET_ARCH_IA32 |
OLD | NEW |