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 486 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
497 Label* early_success, | 497 Label* early_success, |
498 CompareMapMode mode) { | 498 CompareMapMode mode) { |
499 cmp(FieldOperand(obj, HeapObject::kMapOffset), map); | 499 cmp(FieldOperand(obj, HeapObject::kMapOffset), map); |
500 if (mode == ALLOW_ELEMENT_TRANSITION_MAPS) { | 500 if (mode == ALLOW_ELEMENT_TRANSITION_MAPS) { |
501 ElementsKind kind = map->elements_kind(); | 501 ElementsKind kind = map->elements_kind(); |
502 if (IsFastElementsKind(kind)) { | 502 if (IsFastElementsKind(kind)) { |
503 bool packed = IsFastPackedElementsKind(kind); | 503 bool packed = IsFastPackedElementsKind(kind); |
504 Map* current_map = *map; | 504 Map* current_map = *map; |
505 while (CanTransitionToMoreGeneralFastElementsKind(kind, packed)) { | 505 while (CanTransitionToMoreGeneralFastElementsKind(kind, packed)) { |
506 kind = GetNextMoreGeneralFastElementsKind(kind, packed); | 506 kind = GetNextMoreGeneralFastElementsKind(kind, packed); |
507 current_map = current_map->LookupElementsTransitionMap(kind, NULL); | 507 current_map = current_map->LookupElementsTransitionMap(kind); |
508 if (!current_map) break; | 508 if (!current_map) break; |
509 j(equal, early_success, Label::kNear); | 509 j(equal, early_success, Label::kNear); |
510 cmp(FieldOperand(obj, HeapObject::kMapOffset), | 510 cmp(FieldOperand(obj, HeapObject::kMapOffset), |
511 Handle<Map>(current_map)); | 511 Handle<Map>(current_map)); |
512 } | 512 } |
513 } | 513 } |
514 } | 514 } |
515 } | 515 } |
516 | 516 |
517 | 517 |
(...skipping 2304 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2822 // Load the prototype from the map and loop if non-null. | 2822 // Load the prototype from the map and loop if non-null. |
2823 bind(&check_prototype); | 2823 bind(&check_prototype); |
2824 mov(ecx, FieldOperand(ebx, Map::kPrototypeOffset)); | 2824 mov(ecx, FieldOperand(ebx, Map::kPrototypeOffset)); |
2825 cmp(ecx, isolate()->factory()->null_value()); | 2825 cmp(ecx, isolate()->factory()->null_value()); |
2826 j(not_equal, &next); | 2826 j(not_equal, &next); |
2827 } | 2827 } |
2828 | 2828 |
2829 } } // namespace v8::internal | 2829 } } // namespace v8::internal |
2830 | 2830 |
2831 #endif // V8_TARGET_ARCH_IA32 | 2831 #endif // V8_TARGET_ARCH_IA32 |
OLD | NEW |