Add fallthroughs to GetMurmurHash3

This commit is contained in:
Scott Mansell
2026-08-07 19:27:41 +12:00
parent 66d8a89220
commit 4a10a9c634
+14 -1
View File
@@ -136,33 +136,46 @@ static u64 GetMurmurHash3(const u8* src, u32 len, u32 samples)
{ {
case 15: case 15:
k2 ^= u64(tail[14]) << 48; k2 ^= u64(tail[14]) << 48;
[[fallthrough]];
case 14: case 14:
k2 ^= u64(tail[13]) << 40; k2 ^= u64(tail[13]) << 40;
[[fallthrough]];
case 13: case 13:
k2 ^= u64(tail[12]) << 32; k2 ^= u64(tail[12]) << 32;
[[fallthrough]];
case 12: case 12:
k2 ^= u64(tail[11]) << 24; k2 ^= u64(tail[11]) << 24;
[[fallthrough]];
case 11: case 11:
k2 ^= u64(tail[10]) << 16; k2 ^= u64(tail[10]) << 16;
[[fallthrough]];
case 10: case 10:
k2 ^= u64(tail[9]) << 8; k2 ^= u64(tail[9]) << 8;
[[fallthrough]];
case 9: case 9:
k2 ^= u64(tail[8]) << 0; k2 ^= u64(tail[8]) << 0;
[[fallthrough]];
case 8: case 8:
k1 ^= u64(tail[7]) << 56; k1 ^= u64(tail[7]) << 56;
[[fallthrough]];
case 7: case 7:
k1 ^= u64(tail[6]) << 48; k1 ^= u64(tail[6]) << 48;
[[fallthrough]];
case 6: case 6:
k1 ^= u64(tail[5]) << 40; k1 ^= u64(tail[5]) << 40;
[[fallthrough]];
case 5: case 5:
k1 ^= u64(tail[4]) << 32; k1 ^= u64(tail[4]) << 32;
[[fallthrough]];
case 4: case 4:
k1 ^= u64(tail[3]) << 24; k1 ^= u64(tail[3]) << 24;
[[fallthrough]];
case 3: case 3:
k1 ^= u64(tail[2]) << 16; k1 ^= u64(tail[2]) << 16;
[[fallthrough]];
case 2: case 2:
k1 ^= u64(tail[1]) << 8; k1 ^= u64(tail[1]) << 8;
[[fallthrough]];
case 1: case 1:
k1 ^= u64(tail[0]) << 0; k1 ^= u64(tail[0]) << 0;
bmix64(h1, h2, k1, k2, c1, c2); bmix64(h1, h2, k1, k2, c1, c2);