diff --git a/docs/html/annotated.html b/docs/html/annotated.html index 58b855d..2e42cb9 100644 --- a/docs/html/annotated.html +++ b/docs/html/annotated.html @@ -124,25 +124,27 @@ $(function(){initNavTree('annotated.html','',''); });
|
+ libaaruformat 1.0
+
+ Aaru Data Preservation Suite - Format Library
+ |
+
|
+ libaaruformat 1.0
+
+ Aaru Data Preservation Suite - Format Library
+ |
+
C implementation of Aaru file format.
+The target is to be able to compile it with a normal C (C89 compliant) compiler.
+There are no external dependencies.
+cmake is not a hard dependency, it's merely for the ease of using IDEs (specifically CLion).
+Currently supported features:
Things still to be implemented that are already in the C# version:
+Things to be implemented not in the C# version (maybe):
+For debugging memory issues, you can build with Address Sanitizer enabled:
+For detailed information on using Address Sanitizer to detect memory issues, see docs/ASAN_USAGE.md.
+|
+ libaaruformat 1.0
+
+ Aaru Data Preservation Suite - Format Library
+ |
+
Implementation of static-memory hash map with LRU-like eviction. +More...
+#include <stdbool.h>#include <stdint.h>#include <stdlib.h>#include <string.h>#include "aaruformat/static_lru_hash_map.h"Go to the source code of this file.
++Macros | |
| #define | MIN_ACCESS_COUNT 1 |
| New entries start with this access count. | |
| #define | TOMBSTONE_KEY 0 |
| Marker for empty/deleted slots (key=0 reserved). | |
+Functions | |
| static void | age_access_counts (static_lru_hash_map_t *map) |
| Ages all access counts by halving them. | |
| static void | rehash_in_place (static_lru_hash_map_t *map) |
| Rehashes all entries in place after eviction. | |
| static size_t | evict_lru_entries (static_lru_hash_map_t *map, size_t target_count_out) |
| Evicts least-frequently-used entries to make room for new insertions. | |
| static_lru_hash_map_t * | static_lru_create_map (size_t size) |
| Creates a new static LRU hash map with fixed size. | |
| void | static_lru_free_map (static_lru_hash_map_t *map) |
| Frees all memory associated with a static LRU hash map. | |
| bool | static_lru_insert_map (static_lru_hash_map_t *map, uint64_t key, uint64_t value) |
| Inserts a key-value pair into the static LRU hash map. | |
| bool | static_lru_lookup_map (static_lru_hash_map_t *map, uint64_t key, uint64_t *out_value) |
| Looks up a value by key in the static LRU hash map. | |
| bool | static_lru_contains_key (const static_lru_hash_map_t *map, uint64_t key) |
| Checks if a key exists in the map WITHOUT updating access count. | |
| size_t | static_lru_evict (static_lru_hash_map_t *map, size_t entries_to_keep) |
| Manually triggers eviction of least-used entries. | |
| void | static_lru_age_counts (static_lru_hash_map_t *map) |
| Manually ages all access counts. | |
| double | static_lru_load_factor (const static_lru_hash_map_t *map) |
| Returns the current load factor of the map. | |
| size_t | static_lru_free_slots (const static_lru_hash_map_t *map) |
| Returns the number of free slots available. | |
Implementation of static-memory hash map with LRU-like eviction.
+This implementation provides a hash map with:
Eviction Strategy: Approximate LFU (Least Frequently Used) with Aging
Collision Resolution: Open addressing with linear probing (same as hash_map.c)
+ +Definition in file static_lru_hash_map.c.
+| #define MIN_ACCESS_COUNT 1 | +
New entries start with this access count.
+ +Definition at line 49 of file static_lru_hash_map.c.
+ +Referenced by static_lru_insert_map().
+ +| #define TOMBSTONE_KEY 0 | +
Marker for empty/deleted slots (key=0 reserved).
+ +Definition at line 50 of file static_lru_hash_map.c.
+ +Referenced by age_access_counts(), evict_lru_entries(), rehash_in_place(), static_lru_contains_key(), static_lru_insert_map(), and static_lru_lookup_map().
+ +
+
|
+ +static | +
Ages all access counts by halving them.
+This prevents old "hot" entries from permanently occupying the cache. Called automatically every STATIC_LRU_AGING_INTERVAL operations.
+| map | Pointer to the hash map. |
Definition at line 64 of file static_lru_hash_map.c.
+ +References lru_kv_pair_t::access_count, lru_kv_pair_t::key, static_lru_hash_map_t::size, static_lru_hash_map_t::table, and TOMBSTONE_KEY.
+ +Referenced by static_lru_age_counts(), and static_lru_insert_map().
+ +
+
|
+ +static | +
Evicts least-frequently-used entries to make room for new insertions.
+Algorithm:
Time complexity: O(n) where n = map size
+| map | Pointer to the hash map. |
| target_count_out | Target count after eviction. If 0, uses map->target_count. |
Definition at line 139 of file static_lru_hash_map.c.
+ +References lru_kv_pair_t::access_count, static_lru_hash_map_t::count, lru_kv_pair_t::key, rehash_in_place(), static_lru_hash_map_t::size, static_lru_hash_map_t::table, static_lru_hash_map_t::target_count, TOMBSTONE_KEY, and lru_kv_pair_t::value.
+ +Referenced by static_lru_evict(), and static_lru_insert_map().
+ +
+
|
+ +static | +
Rehashes all entries in place after eviction.
+After evicting entries, the linear probing chains are broken. This function rebuilds the table to restore proper probe sequences.
+Note: This temporarily allocates a second table. For truly static memory, a more complex in-place algorithm would be needed.
+| map | Pointer to the hash map. |
Definition at line 87 of file static_lru_hash_map.c.
+ +References static_lru_hash_map_t::count, lru_kv_pair_t::key, static_lru_hash_map_t::size, static_lru_hash_map_t::table, and TOMBSTONE_KEY.
+ +Referenced by evict_lru_entries().
+ +| void static_lru_age_counts | +( | +static_lru_hash_map_t * | map | ) | ++ |
Manually ages all access counts.
+Halves all access counts in the map. This is normally done automatically every STATIC_LRU_AGING_INTERVAL operations, but can be called manually to reset frequency tracking.
+| map | Pointer to the hash map. Must not be NULL. |
Definition at line 331 of file static_lru_hash_map.c.
+ +References age_access_counts(), and static_lru_hash_map_t::age_counter.
+ +| bool static_lru_contains_key | +( | +const static_lru_hash_map_t * | map, | +
| + | + | uint64_t | key ) | +
Checks if a key exists in the map WITHOUT updating access count.
+This is useful when you need to check existence without affecting eviction priority.
+| map | Pointer to the hash map to search. Must not be NULL. |
| key | The key to search for. Must not be 0. |
| true | Key exists in the map. |
| false | Key not found. |
Definition at line 314 of file static_lru_hash_map.c.
+ +References lru_kv_pair_t::key, static_lru_hash_map_t::size, static_lru_hash_map_t::table, and TOMBSTONE_KEY.
+ +| static_lru_hash_map_t * static_lru_create_map | +( | +size_t | size | ) | ++ |
Creates a new static LRU hash map with fixed size.
+Allocates and initializes a new hash map structure with the given size. This is the ONLY allocation that will ever occur for this map - the size is fixed and will never grow. When the map fills up, old entries are evicted instead of allocating more memory.
+| size | Fixed size of the hash table. Enforced minimum is STATIC_LRU_MIN_SIZE. Choose this based on your memory budget and expected working set. |
Definition at line 204 of file static_lru_hash_map.c.
+ +References static_lru_hash_map_t::_padding, static_lru_hash_map_t::age_counter, static_lru_hash_map_t::count, static_lru_hash_map_t::max_count, static_lru_hash_map_t::size, STATIC_LRU_EVICTION_LOAD_FACTOR, STATIC_LRU_MIN_SIZE, STATIC_LRU_TARGET_LOAD_FACTOR, static_lru_hash_map_t::table, and static_lru_hash_map_t::target_count.
+ +| size_t static_lru_evict | +( | +static_lru_hash_map_t * | map, | +
| + | + | size_t | entries_to_keep ) | +
Manually triggers eviction of least-used entries.
+Forces an eviction cycle even if the map hasn't reached the eviction threshold. Useful for proactively freeing memory or resetting the cache.
+| map | Pointer to the hash map. Must not be NULL. |
| entries_to_keep | Number of entries to keep after eviction. If 0, uses target_count. |
Definition at line 328 of file static_lru_hash_map.c.
+ +References evict_lru_entries().
+ +| void static_lru_free_map | +( | +static_lru_hash_map_t * | map | ) | ++ |
Frees all memory associated with a static LRU hash map.
+Deallocates the hash table and the hash map structure itself.
+| map | Pointer to the hash map to free. Can be NULL (no operation performed). |
Definition at line 237 of file static_lru_hash_map.c.
+ +References static_lru_hash_map_t::table.
+ +| size_t static_lru_free_slots | +( | +const static_lru_hash_map_t * | map | ) | ++ |
Returns the number of free slots available.
+| map | Pointer to the hash map. Must not be NULL. |
Definition at line 339 of file static_lru_hash_map.c.
+ +References static_lru_hash_map_t::count, and static_lru_hash_map_t::size.
+ +| bool static_lru_insert_map | +( | +static_lru_hash_map_t * | map, | +
| + | + | uint64_t | key, | +
| + | + | uint64_t | value ) | +
Inserts a key-value pair into the static LRU hash map.
+Adds a new key-value pair to the hash map. If the map is approaching capacity (exceeds STATIC_LRU_EVICTION_LOAD_FACTOR), the least-frequently-used entries are automatically evicted before insertion.
+If the key already exists, the value is updated and the access count is incremented.
+| map | Pointer to the hash map. Must not be NULL. |
| key | The key to insert. Must not be 0 (reserved for empty slots). |
| value | The value to associate with the key. |
| true | Successfully inserted a NEW key-value pair. |
| false | Key already existed; value was updated instead. |
Definition at line 245 of file static_lru_hash_map.c.
+ +References lru_kv_pair_t::access_count, age_access_counts(), static_lru_hash_map_t::age_counter, static_lru_hash_map_t::count, evict_lru_entries(), lru_kv_pair_t::key, static_lru_hash_map_t::max_count, MIN_ACCESS_COUNT, static_lru_hash_map_t::size, STATIC_LRU_AGING_INTERVAL, static_lru_hash_map_t::table, TOMBSTONE_KEY, and lru_kv_pair_t::value.
+ +| double static_lru_load_factor | +( | +const static_lru_hash_map_t * | map | ) | ++ |
Returns the current load factor of the map.
+| map | Pointer to the hash map. Must not be NULL. |
Definition at line 337 of file static_lru_hash_map.c.
+ +References static_lru_hash_map_t::count, and static_lru_hash_map_t::size.
+ +| bool static_lru_lookup_map | +( | +static_lru_hash_map_t * | map, | +
| + | + | uint64_t | key, | +
| + | + | uint64_t * | out_value ) | +
Looks up a value by key in the static LRU hash map.
+Searches for the specified key and retrieves its associated value. Unlike the regular hash_map, this function DOES modify the map by incrementing the access_count of the found entry (to track usage frequency).
+| map | Pointer to the hash map to search. Must not be NULL. |
| key | The key to search for. Must not be 0. |
| out_value | Pointer to store the found value. Must not be NULL. Only modified if the key is found. |
| true | Key found. The associated value is written to *out_value. |
| false | Key not found. *out_value is not modified. |
Definition at line 284 of file static_lru_hash_map.c.
+ +References lru_kv_pair_t::access_count, lru_kv_pair_t::key, static_lru_hash_map_t::size, static_lru_hash_map_t::table, TOMBSTONE_KEY, and lru_kv_pair_t::value.
+ +|
+ libaaruformat 1.0
+
+ Aaru Data Preservation Suite - Format Library
+ |
+
|
+ libaaruformat 1.0
+
+ Aaru Data Preservation Suite - Format Library
+ |
+
Static-memory hash map with LRU-like eviction for fixed RAM usage. +More...
+#include <stdbool.h>#include <stdint.h>#include <stdlib.h>Go to the source code of this file.
++Data Structures | |
| struct | lru_kv_pair_t |
| Single key/value slot with access tracking for the static LRU hash map. More... | |
| struct | static_lru_hash_map_t |
| Fixed-size hash map with LRU-like eviction for bounded memory usage. More... | |
+Macros | |
| #define | STATIC_LRU_EVICTION_LOAD_FACTOR 0.90 |
| Default configuration constants for the static LRU hash map. | |
| #define | STATIC_LRU_TARGET_LOAD_FACTOR 0.75 |
| Evict down to 75% capacity. | |
| #define | STATIC_LRU_AGING_INTERVAL 100000 |
| Age access counts every N operations. | |
| #define | STATIC_LRU_MIN_SIZE 1024 |
| Minimum map size to prevent edge cases. | |
+Functions | |
| static_lru_hash_map_t * | static_lru_create_map (size_t size) |
| Creates a new static LRU hash map with fixed size. | |
| void | static_lru_free_map (static_lru_hash_map_t *map) |
| Frees all memory associated with a static LRU hash map. | |
| bool | static_lru_insert_map (static_lru_hash_map_t *map, uint64_t key, uint64_t value) |
| Inserts a key-value pair into the static LRU hash map. | |
| bool | static_lru_lookup_map (static_lru_hash_map_t *map, uint64_t key, uint64_t *out_value) |
| Looks up a value by key in the static LRU hash map. | |
| bool | static_lru_contains_key (const static_lru_hash_map_t *map, uint64_t key) |
| Checks if a key exists in the map WITHOUT updating access count. | |
| size_t | static_lru_evict (static_lru_hash_map_t *map, size_t entries_to_keep) |
| Manually triggers eviction of least-used entries. | |
| void | static_lru_age_counts (static_lru_hash_map_t *map) |
| Manually ages all access counts. | |
| double | static_lru_load_factor (const static_lru_hash_map_t *map) |
| Returns the current load factor of the map. | |
| size_t | static_lru_free_slots (const static_lru_hash_map_t *map) |
| Returns the number of free slots available. | |
Static-memory hash map with LRU-like eviction for fixed RAM usage.
+This hash map variant has the following characteristics:
Use this instead of hash_map_t when you need predictable, bounded memory usage and can tolerate eviction of less-frequently-accessed entries.
+ +Definition in file static_lru_hash_map.h.
+| #define STATIC_LRU_AGING_INTERVAL 100000 | +
Age access counts every N operations.
+ +Definition at line 55 of file static_lru_hash_map.h.
+ +Referenced by static_lru_insert_map().
+ +| #define STATIC_LRU_EVICTION_LOAD_FACTOR 0.90 | +
Default configuration constants for the static LRU hash map.
+These can be overridden by defining them before including this header. Trigger eviction when 90% full
+ +Definition at line 47 of file static_lru_hash_map.h.
+ +Referenced by static_lru_create_map().
+ +| #define STATIC_LRU_MIN_SIZE 1024 | +
Minimum map size to prevent edge cases.
+ +Definition at line 59 of file static_lru_hash_map.h.
+ +Referenced by static_lru_create_map().
+ +| #define STATIC_LRU_TARGET_LOAD_FACTOR 0.75 | +
Evict down to 75% capacity.
+ +Definition at line 51 of file static_lru_hash_map.h.
+ +Referenced by static_lru_create_map().
+ +| void static_lru_age_counts | +( | +static_lru_hash_map_t * | map | ) | ++ |
Manually ages all access counts.
+Halves all access counts in the map. This is normally done automatically every STATIC_LRU_AGING_INTERVAL operations, but can be called manually to reset frequency tracking.
+| map | Pointer to the hash map. Must not be NULL. |
Definition at line 331 of file static_lru_hash_map.c.
+ +References age_access_counts(), and static_lru_hash_map_t::age_counter.
+ +| bool static_lru_contains_key | +( | +const static_lru_hash_map_t * | map, | +
| + | + | uint64_t | key ) | +
Checks if a key exists in the map WITHOUT updating access count.
+This is useful when you need to check existence without affecting eviction priority.
+| map | Pointer to the hash map to search. Must not be NULL. |
| key | The key to search for. Must not be 0. |
| true | Key exists in the map. |
| false | Key not found. |
Definition at line 314 of file static_lru_hash_map.c.
+ +References lru_kv_pair_t::key, static_lru_hash_map_t::size, static_lru_hash_map_t::table, and TOMBSTONE_KEY.
+ +| static_lru_hash_map_t * static_lru_create_map | +( | +size_t | size | ) | ++ |
Creates a new static LRU hash map with fixed size.
+Allocates and initializes a new hash map structure with the given size. This is the ONLY allocation that will ever occur for this map - the size is fixed and will never grow. When the map fills up, old entries are evicted instead of allocating more memory.
+| size | Fixed size of the hash table. Enforced minimum is STATIC_LRU_MIN_SIZE. Choose this based on your memory budget and expected working set. |
Definition at line 204 of file static_lru_hash_map.c.
+ +References static_lru_hash_map_t::_padding, static_lru_hash_map_t::age_counter, static_lru_hash_map_t::count, static_lru_hash_map_t::max_count, static_lru_hash_map_t::size, STATIC_LRU_EVICTION_LOAD_FACTOR, STATIC_LRU_MIN_SIZE, STATIC_LRU_TARGET_LOAD_FACTOR, static_lru_hash_map_t::table, and static_lru_hash_map_t::target_count.
+ +| size_t static_lru_evict | +( | +static_lru_hash_map_t * | map, | +
| + | + | size_t | entries_to_keep ) | +
Manually triggers eviction of least-used entries.
+Forces an eviction cycle even if the map hasn't reached the eviction threshold. Useful for proactively freeing memory or resetting the cache.
+| map | Pointer to the hash map. Must not be NULL. |
| entries_to_keep | Number of entries to keep after eviction. If 0, uses target_count. |
Definition at line 328 of file static_lru_hash_map.c.
+ +References evict_lru_entries().
+ +| void static_lru_free_map | +( | +static_lru_hash_map_t * | map | ) | ++ |
Frees all memory associated with a static LRU hash map.
+Deallocates the hash table and the hash map structure itself.
+| map | Pointer to the hash map to free. Can be NULL (no operation performed). |
Definition at line 237 of file static_lru_hash_map.c.
+ +References static_lru_hash_map_t::table.
+ +| size_t static_lru_free_slots | +( | +const static_lru_hash_map_t * | map | ) | ++ |
Returns the number of free slots available.
+| map | Pointer to the hash map. Must not be NULL. |
Definition at line 339 of file static_lru_hash_map.c.
+ +References static_lru_hash_map_t::count, and static_lru_hash_map_t::size.
+ +| bool static_lru_insert_map | +( | +static_lru_hash_map_t * | map, | +
| + | + | uint64_t | key, | +
| + | + | uint64_t | value ) | +
Inserts a key-value pair into the static LRU hash map.
+Adds a new key-value pair to the hash map. If the map is approaching capacity (exceeds STATIC_LRU_EVICTION_LOAD_FACTOR), the least-frequently-used entries are automatically evicted before insertion.
+If the key already exists, the value is updated and the access count is incremented.
+| map | Pointer to the hash map. Must not be NULL. |
| key | The key to insert. Must not be 0 (reserved for empty slots). |
| value | The value to associate with the key. |
| true | Successfully inserted a NEW key-value pair. |
| false | Key already existed; value was updated instead. |
Definition at line 245 of file static_lru_hash_map.c.
+ +References lru_kv_pair_t::access_count, age_access_counts(), static_lru_hash_map_t::age_counter, static_lru_hash_map_t::count, evict_lru_entries(), lru_kv_pair_t::key, static_lru_hash_map_t::max_count, MIN_ACCESS_COUNT, static_lru_hash_map_t::size, STATIC_LRU_AGING_INTERVAL, static_lru_hash_map_t::table, TOMBSTONE_KEY, and lru_kv_pair_t::value.
+ +| double static_lru_load_factor | +( | +const static_lru_hash_map_t * | map | ) | ++ |
Returns the current load factor of the map.
+| map | Pointer to the hash map. Must not be NULL. |
Definition at line 337 of file static_lru_hash_map.c.
+ +References static_lru_hash_map_t::count, and static_lru_hash_map_t::size.
+ +| bool static_lru_lookup_map | +( | +static_lru_hash_map_t * | map, | +
| + | + | uint64_t | key, | +
| + | + | uint64_t * | out_value ) | +
Looks up a value by key in the static LRU hash map.
+Searches for the specified key and retrieves its associated value. Unlike the regular hash_map, this function DOES modify the map by incrementing the access_count of the found entry (to track usage frequency).
+| map | Pointer to the hash map to search. Must not be NULL. |
| key | The key to search for. Must not be 0. |
| out_value | Pointer to store the found value. Must not be NULL. Only modified if the key is found. |
| true | Key found. The associated value is written to *out_value. |
| false | Key not found. *out_value is not modified. |
Definition at line 284 of file static_lru_hash_map.c.
+ +References lru_kv_pair_t::access_count, lru_kv_pair_t::key, static_lru_hash_map_t::size, static_lru_hash_map_t::table, TOMBSTONE_KEY, and lru_kv_pair_t::value.
+ +|
+ libaaruformat 1.0
+
+ Aaru Data Preservation Suite - Format Library
+ |
+
|
+ libaaruformat 1.0
+
+ Aaru Data Preservation Suite - Format Library
+ |
+
Single key/value slot with access tracking for the static LRU hash map. + More...
+ +#include <aaruformat/static_lru_hash_map.h>
+Data Fields | |
| uint64_t | key |
| Stored key (64-bit). 0 indicates an empty slot. | |
| uint64_t | value |
| Associated value payload (64-bit). | |
| uint8_t | access_count |
| Access frequency counter (0-255, saturates at 255). | |
| uint8_t | _padding [7] |
| Padding for 8-byte alignment (24 bytes total per entry). | |
Single key/value slot with access tracking for the static LRU hash map.
+Extends the basic kv_pair_t with an access counter to enable LFU-based eviction. The access_count saturates at 255 and is periodically aged (halved) to prevent stale "hot" entries from permanently occupying the cache.
+An empty slot is represented by key == 0. This means 0 cannot be used as a valid key.
+ +Definition at line 71 of file static_lru_hash_map.h.
+| uint8_t lru_kv_pair_t::_padding[7] | +
Padding for 8-byte alignment (24 bytes total per entry).
+ +Definition at line 76 of file static_lru_hash_map.h.
+ +| uint8_t lru_kv_pair_t::access_count | +
Access frequency counter (0-255, saturates at 255).
+ +Definition at line 75 of file static_lru_hash_map.h.
+ +Referenced by age_access_counts(), evict_lru_entries(), static_lru_insert_map(), and static_lru_lookup_map().
+ +| uint64_t lru_kv_pair_t::key | +
Stored key (64-bit). 0 indicates an empty slot.
+ +Definition at line 73 of file static_lru_hash_map.h.
+ +Referenced by age_access_counts(), evict_lru_entries(), rehash_in_place(), static_lru_contains_key(), static_lru_insert_map(), and static_lru_lookup_map().
+ +| uint64_t lru_kv_pair_t::value | +
Associated value payload (64-bit).
+ +Definition at line 74 of file static_lru_hash_map.h.
+ +Referenced by evict_lru_entries(), static_lru_insert_map(), and static_lru_lookup_map().
+ +|
+ libaaruformat 1.0
+
+ Aaru Data Preservation Suite - Format Library
+ |
+
Fixed-size hash map with LRU-like eviction for bounded memory usage. + More...
+ +#include <aaruformat/static_lru_hash_map.h>
+Data Fields | |
| lru_kv_pair_t * | table |
| Array of key/value slots of length == size. | |
| size_t | size |
| Allocated slot capacity (FIXED at creation). | |
| size_t | count |
| Number of active (filled) entries. | |
| size_t | max_count |
| Eviction trigger threshold (size * EVICTION_LOAD_FACTOR). | |
| size_t | target_count |
| Target count after eviction (size * TARGET_LOAD_FACTOR). | |
| uint32_t | age_counter |
| Operations since last aging. | |
| uint32_t | _padding |
| Padding for alignment. | |
Fixed-size hash map with LRU-like eviction for bounded memory usage.
+This map allocates a fixed amount of memory at creation and never grows. When the map approaches capacity (exceeds eviction threshold), it automatically evicts the least-frequently-accessed entries to make room for new insertions.
+Fields:
Memory usage: sizeof(static_lru_hash_map_t) + (size * sizeof(lru_kv_pair_t)) With default 24-byte entries: ~24 bytes per entry + 48 bytes for the struct.
+ +Definition at line 97 of file static_lru_hash_map.h.
+| uint32_t static_lru_hash_map_t::_padding | +
Padding for alignment.
+ +Definition at line 105 of file static_lru_hash_map.h.
+ +Referenced by static_lru_create_map().
+ +| uint32_t static_lru_hash_map_t::age_counter | +
Operations since last aging.
+ +Definition at line 104 of file static_lru_hash_map.h.
+ +Referenced by static_lru_age_counts(), static_lru_create_map(), and static_lru_insert_map().
+ +| size_t static_lru_hash_map_t::count | +
Number of active (filled) entries.
+ +Definition at line 101 of file static_lru_hash_map.h.
+ +Referenced by evict_lru_entries(), rehash_in_place(), static_lru_create_map(), static_lru_free_slots(), static_lru_insert_map(), and static_lru_load_factor().
+ +| size_t static_lru_hash_map_t::max_count | +
Eviction trigger threshold (size * EVICTION_LOAD_FACTOR).
+ +Definition at line 102 of file static_lru_hash_map.h.
+ +Referenced by static_lru_create_map(), and static_lru_insert_map().
+ +| size_t static_lru_hash_map_t::size | +
Allocated slot capacity (FIXED at creation).
+ +Definition at line 100 of file static_lru_hash_map.h.
+ +Referenced by age_access_counts(), evict_lru_entries(), rehash_in_place(), static_lru_contains_key(), static_lru_create_map(), static_lru_free_slots(), static_lru_insert_map(), static_lru_load_factor(), and static_lru_lookup_map().
+ +| lru_kv_pair_t* static_lru_hash_map_t::table | +
Array of key/value slots of length == size.
+ +Definition at line 99 of file static_lru_hash_map.h.
+ +Referenced by age_access_counts(), evict_lru_entries(), rehash_in_place(), static_lru_contains_key(), static_lru_create_map(), static_lru_free_map(), static_lru_insert_map(), and static_lru_lookup_map().
+ +| size_t static_lru_hash_map_t::target_count | +
Target count after eviction (size * TARGET_LOAD_FACTOR).
+ +Definition at line 103 of file static_lru_hash_map.h.
+ +Referenced by evict_lru_entries(), and static_lru_create_map().
+ +