bind9/lib
JINMEI Tatuya 065ffb2eb8
Optimize database decref by avoiding locking with refs > 1
Previously, this function always acquires a node write lock if it
might need node cleanup in case the reference decrements to 0.  In
fact, the lock is unnecessary if the reference is larger than 1 and it
can be optimized as an "easy" case. This optimization could even be
"necessary". In some extreme cases, many worker threads could repeat
acquring and releasing the reference on the same node, resulting in
severe lock contention for nothing (as the ref wouldn't decrement to 0
in most cases). This change would prevent noticeable performance
drop like query timeout for such cases.

Co-authored-by: JINMEI Tatuya <jtatuya@infoblox.com>
Co-authored-by: Ondřej Surý <ondrej@isc.org>

(cherry picked from commit 7f4471594d)
2025-01-22 14:31:09 +01:00
..
bind9 Remove redundant parentheses from the return statement 2024-11-19 16:06:16 +01:00
dns Optimize database decref by avoiding locking with refs > 1 2025-01-22 14:31:09 +01:00
irs Reduce sizeof isc_sockaddr from 152 to 48 bytes 2025-01-22 14:12:38 +01:00
isc Reduce struct isc__nm_uvreq size from 1560 to 560 bytes 2025-01-22 14:12:38 +01:00
isccc Remove redundant parentheses from the return statement 2024-11-19 16:06:16 +01:00
isccfg Implement 'max-query-count' 2024-12-06 15:17:53 +00:00
ns Remove --with-tuning=small/large configuration option 2025-01-22 14:16:40 +01:00
.gitignore The isc/platform.h header has been completely removed 2021-07-06 05:33:48 +00:00
Makefile.am move samples/resolve.c to bin/tests/system 2021-04-16 14:29:43 +02:00