Hi there quick question, how do I know if a platform supports atomic operations on usize?
edit: bad hack removed the cfg()
is way better
It looks like atomic usize
operations are available on any platform where #[cfg(target_has_atomic_load_store = "ptr")]
is set.
The code that sets this cfg
attribute is here.
1 Like
Note that it's guaranteed if the AtomicUsize
type exist.
This type has the same in-memory representation as the underlying integer type
2 Likes
This topic was automatically closed 90 days after the last reply. We invite you to open a new topic if you have further questions or comments.