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

Unified Diff: src/objects-visiting-inl.h

Issue 10837037: Age code to allow reclaiming old unexecuted functions (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Cleanup code Created 8 years, 3 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 side-by-side diff with in-line comments
Download patch
Index: src/objects-visiting-inl.h
diff --git a/src/objects-visiting-inl.h b/src/objects-visiting-inl.h
index 856ae06b7b133bb126371b40fbc42b9eed43b176..5efb4236ddf052db761cdcc82e10ac72e8cd256e 100644
--- a/src/objects-visiting-inl.h
+++ b/src/objects-visiting-inl.h
@@ -229,6 +229,18 @@ void StaticMarkingVisitor<StaticVisitor>::VisitCodeTarget(
template<typename StaticVisitor>
+void StaticMarkingVisitor<StaticVisitor>::VisitCodeAgeSequence(
+ Heap* heap, RelocInfo* rinfo) {
+ ASSERT(RelocInfo::IsCodeAgeSequence(rinfo->rmode()));
+ Code* target = rinfo->code_age_stub();
+ if (target != NULL) {
Michael Starzinger 2012/09/21 09:43:19 We should only reach this visit function if there
danno 2012/10/25 10:07:23 Done.
+ heap->mark_compact_collector()->RecordRelocSlot(rinfo, target);
+ StaticVisitor::MarkObject(heap, target);
+ }
+}
+
+
+template<typename StaticVisitor>
void StaticMarkingVisitor<StaticVisitor>::VisitNativeContext(
Map* map, HeapObject* object) {
FixedBodyVisitor<StaticVisitor,
@@ -251,6 +263,9 @@ void StaticMarkingVisitor<StaticVisitor>::VisitCode(
Map* map, HeapObject* object) {
Heap* heap = map->GetHeap();
Code* code = Code::cast(object);
+ if (!Serializer::enabled()) {
+ code->MakeOlder();
Michael Starzinger 2012/09/21 09:43:19 We can pass heap->mark_compact_collector()->markin
danno 2012/10/25 10:07:23 Done.
+ }
if (FLAG_cleanup_code_caches_at_gc) {
code->ClearTypeFeedbackCells(heap);
}
« src/objects-visiting.h ('K') | « src/objects-visiting.h ('k') | src/serialize.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698