jmorse wrote: IIRC ilist iterators have a strong and stable (!) lifetime guarantee, they just wrap instruction pointers most of the time, so the instruction would need to be erased for it to be invalidated. https://github.com/llvm/llvm-project/pull/73671