Fix the hash function.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@261071 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
David Blaikie 2016-02-17 07:00:22 +00:00
parent ff3f2ebae3
commit 2697fc5688

View File

@ -203,7 +203,7 @@ static void writeIndex(MCStreamer &Out, MCSection *Section,
while (Buckets[H]) {
assert(S != IndexEntries[Buckets[H] - 1].Signature &&
"Duplicate type unit");
H += ((S >> 32) & Mask) | 1;
H = (H + ((S >> 32) & Mask) | 1) % Buckets.size();
}
Buckets[H] = i + 1;
}