]> git.ipfire.org Git - thirdparty/haproxy.git/commit
IMPORT: eb32/64: optimize insert for modern CPUs
authorWilly Tarreau <w@1wt.eu>
Thu, 12 Jun 2025 22:13:06 +0000 (00:13 +0200)
committerWilly Tarreau <w@1wt.eu>
Wed, 17 Sep 2025 12:30:32 +0000 (14:30 +0200)
commit3dda813d544a29e004242a3affcfec21fb1d18d7
treeab4444edaebcee77b526cd009f89d8578bde44ef
parent61654c07bd68e9056d5f66de2c23ab6752cd9fa9
IMPORT: eb32/64: optimize insert for modern CPUs

Similar to previous patches, let's improve the insert() descent loop to
avoid discovering mandatory data too late. The change here is even
simpler than previous ones, a prefetch was installed and troot is
calculated before last instruction in a speculative way. This was enough
to gain +50% insertion rate on random data.

This is ebtree commit e893f8cc4d44b10f406b9d1d78bd4a9bd9183ccf.
include/import/eb32tree.h
include/import/eb64tree.h