[PATCH] D24458: Using murmurhash2 instead of fnv

Rui Ueyama via llvm-commits llvm-commits at lists.llvm.org
Mon Sep 12 10:29:39 PDT 2016


ruiu added inline comments.

================
Comment at: ELF/OutputSections.cpp:1744
@@ -1696,3 +1743,3 @@
 template <class ELFT>
-void BuildIdFnv1<ELFT>::writeBuildId(ArrayRef<uint8_t> Buf) {
+void BuildIdMurmur2<ELFT>::writeBuildId(ArrayRef<uint8_t> Buf) {
   const endianness E = ELFT::TargetEndianness;
----------------
I'd rename this class BuildIdNonCryptoHash or something like that because I think we'd want to change the implementation again in the future. Specifically, we want to use threads to make it faster, but if we do, it is no longer a Murmur hash (because Murmur(concat(X1, X2, ..., Xn)) is different from SomeHash(Murmur(X1), Murmur(X2), ..., Murmur(Xn)).)


https://reviews.llvm.org/D24458





More information about the llvm-commits mailing list