Index: src/objects.h |
=================================================================== |
--- src/objects.h (revision 2481) |
+++ src/objects.h (working copy) |
@@ -2051,11 +2051,6 @@ |
// Casting. |
static inline HashTable* cast(Object* obj); |
- // Compute the probe offset (quadratic probing). |
- INLINE(static uint32_t GetProbeOffset(uint32_t n)) { |
- return (n + n * n) >> 1; |
- } |
- |
static const int kNumberOfElementsIndex = 0; |
static const int kCapacityIndex = 1; |
static const int kPrefixStartIndex = 2; |
@@ -2071,6 +2066,9 @@ |
// Find entry for key otherwise return -1. |
int FindEntry(Key key); |
+ static const uint32_t kNofFastProbes = 4; |
+ static const uint32_t kHashRotateShift = 3; |
+ |
protected: |
// Find the entry at which to insert element with the given key that |
@@ -2096,13 +2094,6 @@ |
fast_set(this, kCapacityIndex, Smi::FromInt(capacity)); |
} |
- |
- // Returns probe entry. |
- static uint32_t GetProbe(uint32_t hash, uint32_t number, uint32_t size) { |
- ASSERT(IsPowerOf2(size)); |
- return (hash + GetProbeOffset(number)) & (size - 1); |
- } |
- |
// Ensure enough space for n additional elements. |
Object* EnsureCapacity(int n, Key key); |
}; |