External Publication
Visit Post

Signal semantics for Rust

Rust Internals [Unofficial] May 10, 2026
Source

Yeah, we should really document this more precisely.

On the opsem side, things behave largely like in C and C++ -- async signals (which also include HW interrupts) are considered basically "separate threads" with all the usual caveats (and data race UB) except that they are paired up with a "main" thread and have a special relationship with that thread (allowing the use of compiler_fence rather than fence when synchronizing with that thread).

Most of the rest of this is a libs question. There, the tl;dr is that std APIs are generally not async-signal-safe.

Discussion in the ATmosphere

Loading comments...