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 2572 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2583 } | 2583 } |
2584 | 2584 |
2585 if (new_number_of_transitions != number_of_transitions) { | 2585 if (new_number_of_transitions != number_of_transitions) { |
2586 map->SetNumberOfProtoTransitions(new_number_of_transitions); | 2586 map->SetNumberOfProtoTransitions(new_number_of_transitions); |
2587 } | 2587 } |
2588 | 2588 |
2589 // Fill slots that became free with undefined value. | 2589 // Fill slots that became free with undefined value. |
2590 for (int i = new_number_of_transitions * step; | 2590 for (int i = new_number_of_transitions * step; |
2591 i < number_of_transitions * step; | 2591 i < number_of_transitions * step; |
2592 i++) { | 2592 i++) { |
2593 prototype_transitions->set_undefined(heap_, header + i); | 2593 prototype_transitions->set_undefined(header + i); |
2594 } | 2594 } |
2595 } | 2595 } |
2596 | 2596 |
2597 | 2597 |
2598 void MarkCompactCollector::ClearNonLiveMapTransitions(Map* map, | 2598 void MarkCompactCollector::ClearNonLiveMapTransitions(Map* map, |
2599 MarkBit map_mark) { | 2599 MarkBit map_mark) { |
2600 Object* potential_parent = map->GetBackPointer(); | 2600 Object* potential_parent = map->GetBackPointer(); |
2601 if (!potential_parent->IsMap()) return; | 2601 if (!potential_parent->IsMap()) return; |
2602 Map* parent = Map::cast(potential_parent); | 2602 Map* parent = Map::cast(potential_parent); |
2603 | 2603 |
(...skipping 1729 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4333 while (buffer != NULL) { | 4333 while (buffer != NULL) { |
4334 SlotsBuffer* next_buffer = buffer->next(); | 4334 SlotsBuffer* next_buffer = buffer->next(); |
4335 DeallocateBuffer(buffer); | 4335 DeallocateBuffer(buffer); |
4336 buffer = next_buffer; | 4336 buffer = next_buffer; |
4337 } | 4337 } |
4338 *buffer_address = NULL; | 4338 *buffer_address = NULL; |
4339 } | 4339 } |
4340 | 4340 |
4341 | 4341 |
4342 } } // namespace v8::internal | 4342 } } // namespace v8::internal |
OLD | NEW |