[llvm] [Support] Add SipHash-based 64-bit stable hash function (PR #160945)
Oliver Hunt via llvm-commits
llvm-commits at lists.llvm.org
Tue Sep 30 02:03:43 PDT 2025
ojhunt wrote:
> > Have you verified arm64e tests are unaffected? In principle codegen should be fine due to truncation, but there's a builtin (`__builtin_ptrauth_string_discriminator`) which may fail
>
> This should be a non-functional change for getPointerAuthStableSipHash() - I just factored out part of it into a separate function that we now expose:
>
> ```
> - uint64_t RawHash = endian::read64le(RawHashBytes);
> + return endian::read64le(RawHashBytes);
> +}
> +
> +/// Compute an ABI-stable 16-bit hash of the given string.
> +uint16_t llvm::getPointerAuthStableSipHash(StringRef Str) {
> + uint64_t RawHash = getStableSipHash(Str);
> ```
>
> Did I miss something?
Sorry I'm a muppet and misread the diff :D
https://github.com/llvm/llvm-project/pull/160945
More information about the llvm-commits
mailing list