| OLD | NEW |
| 1 // Copyright 2009 the V8 project authors. All rights reserved. | 1 // Copyright 2009 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 479 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 490 VerifySymbolTable(); | 490 VerifySymbolTable(); |
| 491 } | 491 } |
| 492 | 492 |
| 493 | 493 |
| 494 void Heap::PostGarbageCollectionProcessing() { | 494 void Heap::PostGarbageCollectionProcessing() { |
| 495 // Process weak handles post gc. | 495 // Process weak handles post gc. |
| 496 { | 496 { |
| 497 DisableAssertNoAllocation allow_allocation; | 497 DisableAssertNoAllocation allow_allocation; |
| 498 GlobalHandles::PostGarbageCollectionProcessing(); | 498 GlobalHandles::PostGarbageCollectionProcessing(); |
| 499 } | 499 } |
| 500 // Update flat string readers. | 500 // Update relocatables. |
| 501 FlatStringReader::PostGarbageCollectionProcessing(); | 501 Relocatable::PostGarbageCollectionProcessing(); |
| 502 } | 502 } |
| 503 | 503 |
| 504 | 504 |
| 505 void Heap::MarkCompact(GCTracer* tracer) { | 505 void Heap::MarkCompact(GCTracer* tracer) { |
| 506 gc_state_ = MARK_COMPACT; | 506 gc_state_ = MARK_COMPACT; |
| 507 mc_count_++; | 507 mc_count_++; |
| 508 tracer->set_full_gc_count(mc_count_); | 508 tracer->set_full_gc_count(mc_count_); |
| 509 LOG(ResourceEvent("markcompact", "begin")); | 509 LOG(ResourceEvent("markcompact", "begin")); |
| 510 | 510 |
| 511 MarkCompactCollector::Prepare(tracer); | 511 MarkCompactCollector::Prepare(tracer); |
| (...skipping 2569 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3081 v->VisitPointers(&roots_[0], &roots_[kStrongRootListLength]); | 3081 v->VisitPointers(&roots_[0], &roots_[kStrongRootListLength]); |
| 3082 SYNCHRONIZE_TAG("strong_root_list"); | 3082 SYNCHRONIZE_TAG("strong_root_list"); |
| 3083 | 3083 |
| 3084 v->VisitPointer(bit_cast<Object**, String**>(&hidden_symbol_)); | 3084 v->VisitPointer(bit_cast<Object**, String**>(&hidden_symbol_)); |
| 3085 SYNCHRONIZE_TAG("symbol"); | 3085 SYNCHRONIZE_TAG("symbol"); |
| 3086 | 3086 |
| 3087 Bootstrapper::Iterate(v); | 3087 Bootstrapper::Iterate(v); |
| 3088 SYNCHRONIZE_TAG("bootstrapper"); | 3088 SYNCHRONIZE_TAG("bootstrapper"); |
| 3089 Top::Iterate(v); | 3089 Top::Iterate(v); |
| 3090 SYNCHRONIZE_TAG("top"); | 3090 SYNCHRONIZE_TAG("top"); |
| 3091 Relocatable::Iterate(v); |
| 3092 SYNCHRONIZE_TAG("relocatable"); |
| 3091 | 3093 |
| 3092 #ifdef ENABLE_DEBUGGER_SUPPORT | 3094 #ifdef ENABLE_DEBUGGER_SUPPORT |
| 3093 Debug::Iterate(v); | 3095 Debug::Iterate(v); |
| 3094 #endif | 3096 #endif |
| 3095 SYNCHRONIZE_TAG("debug"); | 3097 SYNCHRONIZE_TAG("debug"); |
| 3096 CompilationCache::Iterate(v); | 3098 CompilationCache::Iterate(v); |
| 3097 SYNCHRONIZE_TAG("compilationcache"); | 3099 SYNCHRONIZE_TAG("compilationcache"); |
| 3098 | 3100 |
| 3099 // Iterate over local handles in handle scopes. | 3101 // Iterate over local handles in handle scopes. |
| 3100 HandleScopeImplementer::Iterate(v); | 3102 HandleScopeImplementer::Iterate(v); |
| (...skipping 724 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3825 for (int i = 0; i < kNumberOfCaches; i++) { | 3827 for (int i = 0; i < kNumberOfCaches; i++) { |
| 3826 if (caches_[i] != NULL) { | 3828 if (caches_[i] != NULL) { |
| 3827 delete caches_[i]; | 3829 delete caches_[i]; |
| 3828 caches_[i] = NULL; | 3830 caches_[i] = NULL; |
| 3829 } | 3831 } |
| 3830 } | 3832 } |
| 3831 } | 3833 } |
| 3832 | 3834 |
| 3833 | 3835 |
| 3834 } } // namespace v8::internal | 3836 } } // namespace v8::internal |
| OLD | NEW |