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

Unified Diff: src/base/hashmap.h

Issue 2264053003: Keep track of the addition order of variables explicitly. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: rebase Created 4 years, 4 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 | « src/ast/scopes.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/base/hashmap.h
diff --git a/src/base/hashmap.h b/src/base/hashmap.h
index 36755f62c3a051bf4bbe23d2a0515434594a0faf..e3c47de6d7d8af647d6baa6b5069e4290a5ede2b 100644
--- a/src/base/hashmap.h
+++ b/src/base/hashmap.h
@@ -48,7 +48,6 @@ class TemplateHashMapImpl {
void* key;
void* value;
uint32_t hash; // The full hash value for key
- int order; // If you never remove entries this is the insertion order.
};
// If an entry with matching key is found, returns that entry.
@@ -152,7 +151,6 @@ TemplateHashMapImpl<AllocationPolicy>::InsertNew(void* key, uint32_t hash,
p->key = key;
p->value = NULL;
p->hash = hash;
- p->order = occupancy_;
occupancy_++;
// Grow the map if we reached >= 80% occupancy.
@@ -300,7 +298,6 @@ void TemplateHashMapImpl<AllocationPolicy>::Resize(AllocationPolicy allocator) {
if (p->key != NULL) {
Entry* entry = LookupOrInsert(p->key, p->hash, allocator);
entry->value = p->value;
- entry->order = p->order;
n--;
}
}
« no previous file with comments | « src/ast/scopes.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698