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

Unified Diff: src/allocation-tracker.cc

Issue 1074943002: Split TemplateHashMapImpl::Lookup into two methods (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Fix arm (and ppc) builds Created 5 years, 8 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
« no previous file with comments | « no previous file | src/arm/simulator-arm.cc » ('j') | src/hashmap.h » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/allocation-tracker.cc
diff --git a/src/allocation-tracker.cc b/src/allocation-tracker.cc
index 1ad86b88ff8679a1dbf9568eaa8ee7fd022f331c..227d969c2e39c558da21d38566b4b69c69919fab 100644
--- a/src/allocation-tracker.cc
+++ b/src/allocation-tracker.cc
@@ -262,8 +262,8 @@ static uint32_t SnapshotObjectIdHash(SnapshotObjectId id) {
unsigned AllocationTracker::AddFunctionInfo(SharedFunctionInfo* shared,
SnapshotObjectId id) {
- HashMap::Entry* entry = id_to_function_info_index_.Lookup(
- reinterpret_cast<void*>(id), SnapshotObjectIdHash(id), true);
+ HashMap::Entry* entry = id_to_function_info_index_.LookupOrInsert(
+ reinterpret_cast<void*>(id), SnapshotObjectIdHash(id));
if (entry->value == NULL) {
FunctionInfo* info = new FunctionInfo();
info->name = names_->GetFunctionName(shared->DebugName());
« no previous file with comments | « no previous file | src/arm/simulator-arm.cc » ('j') | src/hashmap.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698