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

Unified Diff: src/heap-inl.h

Issue 143153008: The allocation sites scratchpad becomes a heap data structure. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 10 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
« src/heap.cc ('K') | « src/heap.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/heap-inl.h
diff --git a/src/heap-inl.h b/src/heap-inl.h
index 09d754ff82164aa961f6dceba941a0db3460a996..35bad4af39ec94937720004f4e760332c2a0e36b 100644
--- a/src/heap-inl.h
+++ b/src/heap-inl.h
@@ -517,12 +517,8 @@ void Heap::UpdateAllocationSiteFeedback(HeapObject* object) {
AllocationMemento* memento = AllocationMemento::cast(candidate);
if (!memento->IsValid()) return;
- if (memento->GetAllocationSite()->IncrementMementoFoundCount() &&
- heap->allocation_sites_scratchpad_length <
- kAllocationSiteScratchpadSize) {
- heap->allocation_sites_scratchpad[
- heap->allocation_sites_scratchpad_length++] =
- memento->GetAllocationSite();
+ if (memento->GetAllocationSite()->IncrementMementoFoundCount()) {
+ heap->AddAllocationSiteToScratchpad(memento->GetAllocationSite());
}
}
« src/heap.cc ('K') | « src/heap.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698