bind9/tests/isc
Ondřej Surý ddd5586a51
Make isc_mem_isovermem() probabilistic
Replace the hysteretic hi_water/lo_water switch with a stochastic
check: always false below lo_water, always true at or above hi_water,
linearly ramped probability in between.  This spreads cache cleaning
across many inserts instead of triggering a thundering herd once the
hi_water mark is crossed (which causes every addrdataset to enter the
LRU purge path simultaneously and serializes lookups behind the node
write locks).

The is_overmem atomic and its stores are no longer needed and are
removed.  The existing tests that asserted specific hysteretic state
transitions are simplified to check only the deterministic boundaries.

(cherry picked from commit ee24d2a1c3361dcc1c48fb29bb2e0b91bc3405e8)
2026-05-07 13:09:18 +02:00
..
testdata/file Move all the unit tests to /tests/<libname>/ 2022-05-28 14:53:02 -07:00
ascii_test.c Include <inttypes.h> whenever including <cmocka.h> 2023-05-18 15:12:23 +02:00
async_test.c use a thread-local variable to get the current running loop 2024-04-02 10:35:56 +02:00
buffer_test.c Include <inttypes.h> whenever including <cmocka.h> 2023-05-18 15:12:23 +02:00
counter_test.c Include <inttypes.h> whenever including <cmocka.h> 2023-05-18 15:12:23 +02:00
crc64_test.c Use clang-format-20 to update formatting 2025-06-25 13:32:08 +10:00
dnsstream_utils_test.c Remove redundant parentheses from the return statement 2024-11-19 14:26:52 +01:00
dnsstream_utils_test_data.h Add a set of unit tests for dnsbuffer_t and dnsstream_assembler_t 2022-12-20 21:24:45 +02:00
doh_test.c TLS SNI - add low level support for SNI to the networking code 2024-12-26 18:31:03 +02:00
errno_test.c Include <inttypes.h> whenever including <cmocka.h> 2023-05-18 15:12:23 +02:00
file_test.c Use clang-format-22 to update formatting 2026-03-04 12:18:27 +01:00
hash_test.c Remove isc_hash_function macro 2023-09-19 19:56:33 +02:00
hashmap_nodes.h Reduce the size of hashmap_nodes.h file 2024-09-03 14:46:58 +02:00
hashmap_test.c Remove redundant parentheses from the return statement 2024-11-19 14:26:52 +01:00
heap_test.c Remove redundant parentheses from the return statement 2024-11-19 14:26:52 +01:00
histo_test.c Support compilation with cmocka 2.0.0+ 2026-01-07 11:17:42 +01:00
hmac_test.c Use clang-format-20 to update formatting 2025-06-25 13:32:08 +10:00
ht_test.c Fix case insensitive matching in isc_ht hash table implementation 2024-02-11 09:36:56 +01:00
job_test.c use a thread-local variable to get the current running loop 2024-04-02 10:35:56 +02:00
lex_test.c Include <inttypes.h> whenever including <cmocka.h> 2023-05-18 15:12:23 +02:00
loop_test.c complete removal of isc_loop_current() 2024-04-02 10:35:56 +02:00
Makefile.am Drop the unit test for testing randomness 2025-11-04 20:51:22 +01:00
md_test.c Use clang-format-20 to update formatting 2025-06-25 13:32:08 +10:00
mem_test.c Make isc_mem_isovermem() probabilistic 2026-05-07 13:09:18 +02:00
mutex_test.c ISC_RUN_TEST_IMPL should use a static declaration 2026-01-29 00:26:35 +11:00
netaddr_test.c IPv6 case to isc_netaddr_masktoprefixlen tests 2025-03-26 13:30:46 +00:00
netmgr_common.c Use clang-format-20 to update formatting 2025-06-25 13:32:08 +10:00
netmgr_common.h PROXY Stream pre-rendered PROXY handling test 2023-12-06 15:15:25 +02:00
parse_test.c Move all the unit tests to /tests/<libname>/ 2022-05-28 14:53:02 -07:00
proxyheader_test.c Remove redundant parentheses from the return statement 2024-11-19 14:26:52 +01:00
proxyheader_test_data.h Add PROXY header handling unit test suite 2023-12-06 15:15:24 +02:00
proxystream_test.c Remove redundant parentheses from the return statement 2024-11-19 14:26:52 +01:00
proxyudp_test.c Add pre-rendered PROXY header test for PROXY over UDP 2023-12-06 15:15:25 +02:00
quota_test.c Remove redundant parentheses from the return statement 2024-11-19 14:26:52 +01:00
radix_test.c Refactor isc_radix_create to return void 2023-10-13 14:44:40 +02:00
ratelimiter_test.c Remove redundant parentheses from the return statement 2024-11-19 14:26:52 +01:00
regex_test.c Include <inttypes.h> whenever including <cmocka.h> 2023-05-18 15:12:23 +02:00
result_test.c Include <inttypes.h> whenever including <cmocka.h> 2023-05-18 15:12:23 +02:00
rwlock_test.c ISC_RUN_TEST_IMPL should use a static declaration 2026-01-29 00:26:35 +11:00
safe_test.c Include <inttypes.h> whenever including <cmocka.h> 2023-05-18 15:12:23 +02:00
siphash_test.c Implement incremental version of SipHash 2-4 and HalfSipHash 2-4 2023-09-12 16:17:06 +02:00
sockaddr_test.c Include <inttypes.h> whenever including <cmocka.h> 2023-05-18 15:12:23 +02:00
spinlock_test.c ISC_RUN_TEST_IMPL should use a static declaration 2026-01-29 00:26:35 +11:00
stats_test.c Refactor isc_stats_create() and its downstream users to return void 2023-07-27 11:37:44 +02:00
stream_shutdown.c Remove redundant parentheses from the return statement 2024-11-19 14:26:52 +01:00
symtab_test.c Include <inttypes.h> whenever including <cmocka.h> 2023-05-18 15:12:23 +02:00
tcp_test.c Remove redundant parentheses from the return statement 2024-11-19 14:26:52 +01:00
tcpdns_test.c TLS SNI - add low level support for SNI to the networking code 2024-12-26 18:31:03 +02:00
time_test.c Include <inttypes.h> whenever including <cmocka.h> 2023-05-18 15:12:23 +02:00
timer_test.c complete removal of isc_loop_current() 2024-04-02 10:35:56 +02:00
tls_test.c Remove redundant parentheses from the return statement 2024-11-19 14:26:52 +01:00
tlsdns_test.c TLS SNI - add low level support for SNI to the networking code 2024-12-26 18:31:03 +02:00
udp_test.c Refactor UDP tests 2023-12-06 15:15:25 +02:00
uv_wrap.h Remove redundant parentheses from the return statement 2024-11-19 14:26:52 +01:00
work_test.c Enforce isc_work enqueue loop affinity 2026-03-14 07:52:56 +01:00