Add optimized functions for linear search within byte arrays

John Naylor <john.naylor@postgresql.org>

Commit: e813e0e16852c080259cd0813e1a82ecb2625aea
Author: John Naylor <john.naylor@postgresql.org>
Date: 2022-08-26T07:03:39Z
Releases: 16.0
Add optimized functions for linear search within byte arrays

In similar vein to b6ef167564, add pg_lfind8() and pg_lfind8_le()
to search for bytes equal or less-than-or-equal to a given byte,
respectively. To abstract away platform details, add helper functions
and typedefs to simd.h.

John Naylor and Nathan Bossart, per suggestion from Andres Freund

Discussion: https://www.postgresql.org/message-id/CAFBsxsGzaaGLF%3DNuq61iRXTyspbO9rOjhSqFN%3DV6ozzmta5mXg%40mail.gmail.com

Files

Discussion