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 2742 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2753 Label* early_success, | 2753 Label* early_success, |
2754 CompareMapMode mode) { | 2754 CompareMapMode mode) { |
2755 Cmp(FieldOperand(obj, HeapObject::kMapOffset), map); | 2755 Cmp(FieldOperand(obj, HeapObject::kMapOffset), map); |
2756 if (mode == ALLOW_ELEMENT_TRANSITION_MAPS) { | 2756 if (mode == ALLOW_ELEMENT_TRANSITION_MAPS) { |
2757 ElementsKind kind = map->elements_kind(); | 2757 ElementsKind kind = map->elements_kind(); |
2758 if (IsFastElementsKind(kind)) { | 2758 if (IsFastElementsKind(kind)) { |
2759 bool packed = IsFastPackedElementsKind(kind); | 2759 bool packed = IsFastPackedElementsKind(kind); |
2760 Map* current_map = *map; | 2760 Map* current_map = *map; |
2761 while (CanTransitionToMoreGeneralFastElementsKind(kind, packed)) { | 2761 while (CanTransitionToMoreGeneralFastElementsKind(kind, packed)) { |
2762 kind = GetNextMoreGeneralFastElementsKind(kind, packed); | 2762 kind = GetNextMoreGeneralFastElementsKind(kind, packed); |
2763 current_map = current_map->LookupElementsTransitionMap(kind, NULL); | 2763 current_map = current_map->LookupElementsTransitionMap(kind); |
2764 if (!current_map) break; | 2764 if (!current_map) break; |
2765 j(equal, early_success, Label::kNear); | 2765 j(equal, early_success, Label::kNear); |
2766 Cmp(FieldOperand(obj, HeapObject::kMapOffset), | 2766 Cmp(FieldOperand(obj, HeapObject::kMapOffset), |
2767 Handle<Map>(current_map)); | 2767 Handle<Map>(current_map)); |
2768 } | 2768 } |
2769 } | 2769 } |
2770 } | 2770 } |
2771 } | 2771 } |
2772 | 2772 |
2773 | 2773 |
(...skipping 1672 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4446 bind(&check_prototype); | 4446 bind(&check_prototype); |
4447 movq(rcx, FieldOperand(rbx, Map::kPrototypeOffset)); | 4447 movq(rcx, FieldOperand(rbx, Map::kPrototypeOffset)); |
4448 cmpq(rcx, null_value); | 4448 cmpq(rcx, null_value); |
4449 j(not_equal, &next); | 4449 j(not_equal, &next); |
4450 } | 4450 } |
4451 | 4451 |
4452 | 4452 |
4453 } } // namespace v8::internal | 4453 } } // namespace v8::internal |
4454 | 4454 |
4455 #endif // V8_TARGET_ARCH_X64 | 4455 #endif // V8_TARGET_ARCH_X64 |
OLD | NEW |