class GrowthInfo

Defined at line 696 of file ../../third_party/abseil-cpp/src/absl/container/internal/raw_hash_set.h

Stored the information regarding number of slots we can still fill

without needing to rehash.

We want to ensure sufficient number of empty slots in the table in order

to keep probe sequences relatively short. Empty slot in the probe group

is required to stop probing.

Tombstones (kDeleted slots) are not included in the growth capacity,

because we'd like to rehash when the table is filled with tombstones and/or

full slots.

GrowthInfo also stores a bit that encodes whether table may have any

deleted slots.

Most of the tables (>95%) have no deleted slots, so some functions can

be more efficient with this information.

Callers can also force a rehash via the standard `rehash(0)`,

which will recompute this value as a side-effect.

See also `CapacityToGrowth()`.

Public Methods

void GrowthInfo ()

Leaves data member uninitialized.

Defined at line 699 of file ../../third_party/abseil-cpp/src/absl/container/internal/raw_hash_set.h

void InitGrowthLeftNoDeleted (size_t growth_left)

Initializes the GrowthInfo assuming we can grow `growth_left` elements

and there are no kDeleted slots in the table.

Defined at line 703 of file ../../third_party/abseil-cpp/src/absl/container/internal/raw_hash_set.h

void OverwriteFullAsEmpty ()

Overwrites single full slot with an empty slot.

Defined at line 708 of file ../../third_party/abseil-cpp/src/absl/container/internal/raw_hash_set.h

void OverwriteEmptyAsFull ()

Overwrites single empty slot with a full slot.

Defined at line 711 of file ../../third_party/abseil-cpp/src/absl/container/internal/raw_hash_set.h

void OverwriteManyEmptyAsFull (size_t count)

Overwrites several empty slots with full slots.

Defined at line 717 of file ../../third_party/abseil-cpp/src/absl/container/internal/raw_hash_set.h

void OverwriteControlAsFull (ctrl_t ctrl)

Overwrites specified control element with full slot.

Defined at line 723 of file ../../third_party/abseil-cpp/src/absl/container/internal/raw_hash_set.h

void OverwriteFullAsDeleted ()

Overwrites single full slot with a deleted slot.

Defined at line 730 of file ../../third_party/abseil-cpp/src/absl/container/internal/raw_hash_set.h

bool HasNoDeletedAndGrowthLeft ()

Returns true if table satisfies two properties:

1. Guaranteed to have no kDeleted slots.

2. There is a place for at least one element to grow.

Defined at line 735 of file ../../third_party/abseil-cpp/src/absl/container/internal/raw_hash_set.h

bool HasNoGrowthLeftAndNoDeleted ()

Returns true if the table satisfies two properties:

1. Guaranteed to have no kDeleted slots.

2. There is no growth left.

Defined at line 742 of file ../../third_party/abseil-cpp/src/absl/container/internal/raw_hash_set.h

bool HasNoGrowthLeftAssumingMayHaveDeleted ()

Returns true if GetGrowthLeft() == 0, but must be called only if

HasNoDeleted() is false. It is slightly more efficient.

Defined at line 746 of file ../../third_party/abseil-cpp/src/absl/container/internal/raw_hash_set.h

bool HasNoDeleted ()

Returns true if table guaranteed to have no kDeleted slots.

Defined at line 752 of file ../../third_party/abseil-cpp/src/absl/container/internal/raw_hash_set.h

size_t GetGrowthLeft ()

Returns the number of elements left to grow.

Defined at line 757 of file ../../third_party/abseil-cpp/src/absl/container/internal/raw_hash_set.h