| OLD | NEW |
| 1 // Copyright 2006-2008 the V8 project authors. All rights reserved. | 1 // Copyright 2006-2008 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 24 matching lines...) Expand all Loading... |
| 35 | 35 |
| 36 namespace v8 { namespace internal { | 36 namespace v8 { namespace internal { |
| 37 | 37 |
| 38 #ifdef DEBUG | 38 #ifdef DEBUG |
| 39 // The verification code used between phases of the m-c collector does not | 39 // The verification code used between phases of the m-c collector does not |
| 40 // currently work. | 40 // currently work. |
| 41 // | 41 // |
| 42 // TODO(1240833): Fix the heap verification code and turn this into a real | 42 // TODO(1240833): Fix the heap verification code and turn this into a real |
| 43 // flag. | 43 // flag. |
| 44 static const bool FLAG_verify_global_gc = false; | 44 static const bool FLAG_verify_global_gc = false; |
| 45 | |
| 46 DECLARE_bool(gc_verbose); | |
| 47 #endif // DEBUG | 45 #endif // DEBUG |
| 48 | 46 |
| 49 DEFINE_bool(always_compact, false, "Perform compaction on every full GC"); | |
| 50 DEFINE_bool(never_compact, false, | |
| 51 "Never perform compaction on full GC - testing only"); | |
| 52 | |
| 53 DEFINE_bool(cleanup_ics_at_gc, true, | |
| 54 "Flush inline caches prior to mark compact collection."); | |
| 55 DEFINE_bool(cleanup_caches_in_maps_at_gc, true, | |
| 56 "Flush code caches in maps during mark compact cycle."); | |
| 57 | |
| 58 DECLARE_bool(gc_global); | |
| 59 | |
| 60 // ---------------------------------------------------------------------------- | 47 // ---------------------------------------------------------------------------- |
| 61 // MarkCompactCollector | 48 // MarkCompactCollector |
| 62 | 49 |
| 63 bool MarkCompactCollector::compacting_collection_ = false; | 50 bool MarkCompactCollector::compacting_collection_ = false; |
| 64 | 51 |
| 65 int MarkCompactCollector::previous_marked_count_ = 0; | 52 int MarkCompactCollector::previous_marked_count_ = 0; |
| 66 GCTracer* MarkCompactCollector::tracer_ = NULL; | 53 GCTracer* MarkCompactCollector::tracer_ = NULL; |
| 67 | 54 |
| 68 | 55 |
| 69 #ifdef DEBUG | 56 #ifdef DEBUG |
| (...skipping 1709 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1779 | 1766 |
| 1780 void MarkCompactCollector::RebuildRSets() { | 1767 void MarkCompactCollector::RebuildRSets() { |
| 1781 #ifdef DEBUG | 1768 #ifdef DEBUG |
| 1782 ASSERT(state_ == RELOCATE_OBJECTS); | 1769 ASSERT(state_ == RELOCATE_OBJECTS); |
| 1783 state_ = REBUILD_RSETS; | 1770 state_ = REBUILD_RSETS; |
| 1784 #endif | 1771 #endif |
| 1785 Heap::RebuildRSets(); | 1772 Heap::RebuildRSets(); |
| 1786 } | 1773 } |
| 1787 | 1774 |
| 1788 } } // namespace v8::internal | 1775 } } // namespace v8::internal |
| OLD | NEW |