We currently build with -fno-builtin-memcmp on all platforms, but the bug it was working around (https://gcc.gnu.org/bugzilla/show_bug.cgi?id=43052) was only ever an x86_64 issue. We should allow the compiler to do what it wants on non-x86_64 platforms.
Note that we have SERVER-55132 to investigate whether the flag can now be removed on x86_64, since we expect it is no longer needed there either with modern GCC. But there is no reason to penalize the other platforms while we wait.
We should probably also restrict application to GCC, since, again, clang isn't affected.