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

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

Issue 9608006: Add kAbortIncrementalMarkingMask flag for GC. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 8 years, 9 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
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 668 matching lines...) Expand 10 before | Expand all | Expand 10 after
679 ASSERT(!FLAG_never_compact || !FLAG_always_compact); 679 ASSERT(!FLAG_never_compact || !FLAG_always_compact);
680 680
681 if (collect_maps_) CreateBackPointers(); 681 if (collect_maps_) CreateBackPointers();
682 #ifdef ENABLE_GDB_JIT_INTERFACE 682 #ifdef ENABLE_GDB_JIT_INTERFACE
683 if (FLAG_gdbjit) { 683 if (FLAG_gdbjit) {
684 // If GDBJIT interface is active disable compaction. 684 // If GDBJIT interface is active disable compaction.
685 compacting_collection_ = false; 685 compacting_collection_ = false;
686 } 686 }
687 #endif 687 #endif
688 688
689 // Clear marking bits for precise sweeping to collect all garbage. 689 // Clear marking bits if incremental marking is aborted (required for
690 if (was_marked_incrementally_ && PreciseSweepingRequired()) { 690 // precise sweeping to collect all garbage).
691 ASSERT(abort_incremental_marking_ || !sweep_precisely_);
692 if (was_marked_incrementally_ && abort_incremental_marking_) {
691 heap()->incremental_marking()->Abort(); 693 heap()->incremental_marking()->Abort();
692 ClearMarkbits(); 694 ClearMarkbits();
693 AbortCompaction(); 695 AbortCompaction();
694 was_marked_incrementally_ = false; 696 was_marked_incrementally_ = false;
695 } 697 }
696 698
697 // Don't start compaction if we are in the middle of incremental 699 // Don't start compaction if we are in the middle of incremental
698 // marking cycle. We did not collect any slots. 700 // marking cycle. We did not collect any slots.
699 if (!FLAG_never_compact && !was_marked_incrementally_) { 701 if (!FLAG_never_compact && !was_marked_incrementally_) {
700 StartCompaction(NON_INCREMENTAL_COMPACTION); 702 StartCompaction(NON_INCREMENTAL_COMPACTION);
(...skipping 3428 matching lines...) Expand 10 before | Expand all | Expand 10 after
4129 while (buffer != NULL) { 4131 while (buffer != NULL) {
4130 SlotsBuffer* next_buffer = buffer->next(); 4132 SlotsBuffer* next_buffer = buffer->next();
4131 DeallocateBuffer(buffer); 4133 DeallocateBuffer(buffer);
4132 buffer = next_buffer; 4134 buffer = next_buffer;
4133 } 4135 }
4134 *buffer_address = NULL; 4136 *buffer_address = NULL;
4135 } 4137 }
4136 4138
4137 4139
4138 } } // namespace v8::internal 4140 } } // namespace v8::internal
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698