|
|
|
|
|
by tpolzer
3070 days ago
|
|
If you really want that, just do a relaxed read into a local variable, increment there and relaxed store afterwards. At least clang will give you exactly the assembly you want, minus the technically undefined behavior:
https://godbolt.org/g/9ikt1m |
|