OLD | NEW |
1 // Copyright 2010 the V8 project authors. All rights reserved. | 1 // Copyright 2010 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 667 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
678 } else { | 678 } else { |
679 set_survival_rate_trend(STABLE); | 679 set_survival_rate_trend(STABLE); |
680 } | 680 } |
681 | 681 |
682 survival_rate_ = survival_rate; | 682 survival_rate_ = survival_rate; |
683 } | 683 } |
684 | 684 |
685 void Heap::PerformGarbageCollection(GarbageCollector collector, | 685 void Heap::PerformGarbageCollection(GarbageCollector collector, |
686 GCTracer* tracer, | 686 GCTracer* tracer, |
687 CollectionPolicy collectionPolicy) { | 687 CollectionPolicy collectionPolicy) { |
| 688 if (collector != SCAVENGER) { |
| 689 PROFILE(CodeMovingGCEvent()); |
| 690 } |
| 691 |
688 VerifySymbolTable(); | 692 VerifySymbolTable(); |
689 if (collector == MARK_COMPACTOR && global_gc_prologue_callback_) { | 693 if (collector == MARK_COMPACTOR && global_gc_prologue_callback_) { |
690 ASSERT(!allocation_allowed_); | 694 ASSERT(!allocation_allowed_); |
691 GCTracer::Scope scope(tracer, GCTracer::Scope::EXTERNAL); | 695 GCTracer::Scope scope(tracer, GCTracer::Scope::EXTERNAL); |
692 global_gc_prologue_callback_(); | 696 global_gc_prologue_callback_(); |
693 } | 697 } |
694 | 698 |
695 GCType gc_type = | 699 GCType gc_type = |
696 collector == MARK_COMPACTOR ? kGCTypeMarkSweepCompact : kGCTypeScavenge; | 700 collector == MARK_COMPACTOR ? kGCTypeMarkSweepCompact : kGCTypeScavenge; |
697 | 701 |
(...skipping 4298 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4996 void ExternalStringTable::TearDown() { | 5000 void ExternalStringTable::TearDown() { |
4997 new_space_strings_.Free(); | 5001 new_space_strings_.Free(); |
4998 old_space_strings_.Free(); | 5002 old_space_strings_.Free(); |
4999 } | 5003 } |
5000 | 5004 |
5001 | 5005 |
5002 List<Object*> ExternalStringTable::new_space_strings_; | 5006 List<Object*> ExternalStringTable::new_space_strings_; |
5003 List<Object*> ExternalStringTable::old_space_strings_; | 5007 List<Object*> ExternalStringTable::old_space_strings_; |
5004 | 5008 |
5005 } } // namespace v8::internal | 5009 } } // namespace v8::internal |
OLD | NEW |