Permalink
Browse files

Minor optimization.

  • Loading branch information...
hrydgard committed Nov 1, 2017
1 parent b9d990a commit 0e5b398c9d3e6a645f607a9fe47282012959c13f
Showing with 2 additions and 6 deletions.
  1. +2 −6 Common/Hashmaps.h
View
@@ -127,9 +127,7 @@ class DenseHashMap {
}
void Clear() {
for (int i = 0; i < state.size(); i++) {
state[i] = BucketState::FREE;
}
memset(state.data(), (int)BucketState::FREE, state.size());
}
void Rebuild() {
@@ -266,9 +264,7 @@ class PrehashMap {
}
void Clear() {
for (int i = 0; i < state.size(); i++) {
state[i] = BucketState::FREE;
}
memset(state.data(), (int)BucketState::FREE, state.size());
}
// Gets rid of REMOVED tombstones, making lookups somewhat more efficient.

0 comments on commit 0e5b398

Please sign in to comment.