]> git.ipfire.org Git - thirdparty/haproxy.git/commit
IMPORT: ebtree: only use __builtin_prefetch() when supported
authorWilly Tarreau <w@1wt.eu>
Sat, 5 Jul 2025 19:57:33 +0000 (21:57 +0200)
committerWilly Tarreau <w@1wt.eu>
Wed, 17 Sep 2025 12:30:32 +0000 (14:30 +0200)
commitfef4cfbd212df508f2d2681b845fcd8c8c2593a1
tree805d22f2c1df8400cff2d3b00a9bab3dcaf675f7
parent3dda813d544a29e004242a3affcfec21fb1d18d7
IMPORT: ebtree: only use __builtin_prefetch() when supported

It looks like __builtin_prefetch() appeared in gcc-3.1 as there's no
mention of it in 3.0's doc. Let's replace it with eb_prefetch() which
maps to __builtin_prefetch() on supported compilers and falls back to
the usual do{}while(0) on other ones. It was tested to properly build
with tcc as well as gcc-2.95.

This is ebtree commit 7ee6ede56a57a046cb552ed31302b93ff1a21b1a.
include/import/eb32tree.h
include/import/eb64tree.h
include/import/ebmbtree.h
include/import/ebtree.h
src/eb32tree.c
src/eb64tree.c