[PATCH] D59116: [scudo][standalone] Implement checksumming functions

Kostya Kortchinsky via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Mar 8 08:55:24 PST 2019


cryptoad added a comment.

In D59116#1422442 <https://reviews.llvm.org/D59116#1422442>, @mgorny wrote:

> If you have to bundle a new hash, have you considered using one of the modern fast hashes (such as xxHash, CityHash, …)?


For Scudo, we need something that will checksum 96bits on 32-bit & 160 bits on 64-bit with as few cycles as possible, and that can (hopefully) detect corruption.
CityHash & xxHash are, in my opinion, way too complex for our use case, and likely slower than the BSD checksum for software. HW CRC32 ends up being a couple of asm instructions and is super quick for our purpose.
So in the end, I do not think that those hashes would be worth using here.


Repository:
  rCRT Compiler Runtime

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D59116/new/

https://reviews.llvm.org/D59116





More information about the llvm-commits mailing list