Avoid overhead of comparision function pointer calls in lpFind() (#13503)
In #13279 (found by @filipecosta90), for custom lookups, we introduce a
comparison function for `lpFind()` to compare entry, but it also
introduces some overhead.
To avoid the overhead of function pointer calls:
1. Extract the lpFindCb() method into a lpFindCbInternal() method that
is easier to inline.
2. Use unlikely to annotate the comparison method, as can only success
once.
---------
Co-authored-by:
Ozan Tezcan <ozantezcan@gmail.com>
Please register or sign in to comment