mirror of
https://github.com/siemens-mobile-hacks/llvm-c166.git
synced 2026-11-25 21:45:57 +00:00
Reland #202103 after relanding "[StringMap] Invalidate iterators in remove()" (#203249) StringMap uses quadratic probing with lazy deletion: an erased entry becomes a tombstone, a third bucket state alongside empty and live that every find/insert must inspect. Switch to linear probing with Knuth TAOCP 6.4 Algorithm R deletion, similar to DenseMap #200595. erase now relocates the following entries to close the hole. StringMap buckets are pointers to heap-allocated entries, so only the pointers (and the parallel hash array) move. References and pointers to entries remain valid, but iterators are invalidated. Depends on #202237 and #202520 Aided by Claude Opus 4.8 |
||
|---|---|---|
| .. | ||
| prettyprinters.py | ||