Include racy reads in Rust memory model with `MaybeInvalid<T>`
Rust Internals [Unofficial]
May 12, 2026
RalfJung:
(Miri of course already has the same problem for the variant of this program where the two loads are
Ordering::Relaxed. But given that only a tiny fraction of reads in any given program use that ordering, I think it is a very different situation if we have that problem for all reads vs. only for a few of them.)
I would likewise expect that very few pieces of data in a program would use this kind of pseudo-cell that permits racy reads. By way of example, the Linux kernel has RCU, but the actual fraction of pointers managed by RCU is a small fraction of pointers in the kernel.
I would love to see a mechanism for this.
Discussion in the ATmosphere