Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1630)

Side by Side Diff: src/mark-compact.cc

Issue 12094057: Fixes Windows build bots. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 3570 matching lines...) Expand 10 before | Expand all | Expand 10 after
3581 Address block_address = p->area_start(); 3581 Address block_address = p->area_start();
3582 3582
3583 // Skip over all the dead objects at the start of the page and mark them free. 3583 // Skip over all the dead objects at the start of the page and mark them free.
3584 for (; 3584 for (;
3585 cell_index < last_cell_index; 3585 cell_index < last_cell_index;
3586 cell_index++, block_address += 32 * kPointerSize) { 3586 cell_index++, block_address += 32 * kPointerSize) {
3587 if (cells[cell_index] != 0) break; 3587 if (cells[cell_index] != 0) break;
3588 } 3588 }
3589 size_t size = block_address - p->area_start(); 3589 size_t size = block_address - p->area_start();
3590 if (cell_index == last_cell_index) { 3590 if (cell_index == last_cell_index) {
3591 freed_bytes += Free<mode>(space, free_list, p->area_start(), size); 3591 freed_bytes += Free<mode>(space, free_list, p->area_start(),
3592 static_cast<int>(size));
3592 ASSERT_EQ(0, p->LiveBytes()); 3593 ASSERT_EQ(0, p->LiveBytes());
3593 return freed_bytes; 3594 return freed_bytes;
3594 } 3595 }
3595 // Grow the size of the start-of-page free space a little to get up to the 3596 // Grow the size of the start-of-page free space a little to get up to the
3596 // first live object. 3597 // first live object.
3597 Address free_end = StartOfLiveObject(block_address, cells[cell_index]); 3598 Address free_end = StartOfLiveObject(block_address, cells[cell_index]);
3598 // Free the first free space. 3599 // Free the first free space.
3599 size = free_end - p->area_start(); 3600 size = free_end - p->area_start();
3600 freed_bytes += Free<mode>(space, free_list, p->area_start(), size); 3601 freed_bytes += Free<mode>(space, free_list, p->area_start(),
3602 static_cast<int>(size));
3601 3603
3602 // The start of the current free area is represented in undigested form by 3604 // The start of the current free area is represented in undigested form by
3603 // the address of the last 32-word section that contained a live object and 3605 // the address of the last 32-word section that contained a live object and
3604 // the marking bitmap for that cell, which describes where the live object 3606 // the marking bitmap for that cell, which describes where the live object
3605 // started. Unless we find a large free space in the bitmap we will not 3607 // started. Unless we find a large free space in the bitmap we will not
3606 // digest this pair into a real address. We start the iteration here at the 3608 // digest this pair into a real address. We start the iteration here at the
3607 // first word in the marking bit map that indicates a live object. 3609 // first word in the marking bit map that indicates a live object.
3608 Address free_start = block_address; 3610 Address free_start = block_address;
3609 uint32_t free_start_cell = cells[cell_index]; 3611 uint32_t free_start_cell = cells[cell_index];
3610 3612
(...skipping 404 matching lines...) Expand 10 before | Expand all | Expand 10 after
4015 while (buffer != NULL) { 4017 while (buffer != NULL) {
4016 SlotsBuffer* next_buffer = buffer->next(); 4018 SlotsBuffer* next_buffer = buffer->next();
4017 DeallocateBuffer(buffer); 4019 DeallocateBuffer(buffer);
4018 buffer = next_buffer; 4020 buffer = next_buffer;
4019 } 4021 }
4020 *buffer_address = NULL; 4022 *buffer_address = NULL;
4021 } 4023 }
4022 4024
4023 4025
4024 } } // namespace v8::internal 4026 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698