parent
d2f44d8de0
commit
9b49256fa8
|
@ -288,10 +288,11 @@ writeIndex(MCStreamer &Out, MCSection *Section,
|
||||||
for (const auto &P : IndexEntries) {
|
for (const auto &P : IndexEntries) {
|
||||||
auto S = P.first;
|
auto S = P.first;
|
||||||
auto H = S & Mask;
|
auto H = S & Mask;
|
||||||
|
auto HP = ((S >> 32) & Mask) | 1;
|
||||||
while (Buckets[H]) {
|
while (Buckets[H]) {
|
||||||
assert(S != IndexEntries.begin()[Buckets[H] - 1].first &&
|
assert(S != IndexEntries.begin()[Buckets[H] - 1].first &&
|
||||||
"Duplicate unit");
|
"Duplicate unit");
|
||||||
H = (H + (((S >> 32) & Mask) | 1)) % Buckets.size();
|
H = (H + HP) & Mask;
|
||||||
}
|
}
|
||||||
Buckets[H] = i + 1;
|
Buckets[H] = i + 1;
|
||||||
++i;
|
++i;
|
||||||
|
|
Loading…
Reference in New Issue