[llvm] [ADT] Remove zombie-instance handling from SmallDenseMapStorage (NFC) (PR #228925)

Fangrui Song via llvm-commits llvm-commits at lists.llvm.org
Sun Oct 4 12:21:21 PDT 2026


MaskRay wrote:

 LGTM. One process note: this is the second half of #228802 — that patch removed SmallDenseMapStorage::kill() ("Put the zombie instance in a known good state after a move") but kept the "zombie instances" guard in deallocateBuckets() a few lines below, which existed for the same temporary. When a patch retires an invariant, please grep for its other dependents (here, zombie / NumBuckets == 0) and fold the cleanup into the same PR. A split like this costs an extra review round and leaves an intermediate state on main that nobody intended.

In the same vein, DenseMapStorage::maybeMoveFast can now be *this = Other; — the swap only existed so Tmp's destructor would free the old storage. Mind folding that in here?

https://github.com/llvm/llvm-project/pull/228925


More information about the llvm-commits mailing list