Hi,

Thanks for the explanation which helps me a lot!


The bsearch() got inlined according to compiler explorer:


https://godbolt.org/z/1x69zGMcn


So we'd probably need our own inline function to keep the playing
field level.  Some tweaked algorithms[1] are also said to speed up
small integer tables, Unicode tables etc.
How about add a pg_bsearch() and #define bsearch(a,b,c,d,e) 
pg_bsearch(a,b,c,d,e) to use it?


--
Regards,
ChangAo Chen

Reply via email to