From: Christian Weisgerber Subject: Re: [PATCH] amd64: import optimized memcmp from FreeBSD To: tech@openbsd.org Date: Sat, 30 Nov 2024 20:06:39 +0100 Theo de Raadt: > > FreeBSD already did all that work recently. > > https://freebsdfoundation.org/blog/a-sneak-peek-simd-enhanced-string-functions-for-amd64/ > > That uses ifuncs. Yes, and an environment variable to pick your implementation at runtime. Seriously. None of that would keep us from just importing the variant optimized for the architectural baseline, e.g. SSE2 for amd64 libc. There are aarch64 versions as well. -- Christian "naddy" Weisgerber naddy@mips.inka.de