Index: src/allocation-tracker.cc |
diff --git a/src/allocation-tracker.cc b/src/allocation-tracker.cc |
index 28883ae740d45a6b4bcbb5df70b7ffc4929feca9..8044cef3c810b42e3bce9eb47fe1c25d3cc3d411 100644 |
--- a/src/allocation-tracker.cc |
+++ b/src/allocation-tracker.cc |
@@ -169,7 +169,7 @@ void AllocationTracker::PrepareForSerialization() { |
} |
-void AllocationTracker::NewObjectEvent(Address addr, int size) { |
+void AllocationTracker::AllocationEvent(Address addr, int size) { |
DisallowHeapAllocation no_allocation; |
Heap* heap = ids_->heap(); |
@@ -185,7 +185,8 @@ void AllocationTracker::NewObjectEvent(Address addr, int size) { |
while (!it.done() && length < kMaxAllocationTraceLength) { |
JavaScriptFrame* frame = it.frame(); |
SharedFunctionInfo* shared = frame->function()->shared(); |
- SnapshotObjectId id = ids_->FindEntry(shared->address()); |
+ SnapshotObjectId id = ids_->FindOrAddEntry( |
+ shared->address(), shared->Size(), false); |
allocation_trace_buffer_[length++] = id; |
AddFunctionInfo(shared, id); |
it.Advance(); |