Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- void test(bool desired, int volatile *p) {
- __asm__ __volatile__("xchg %[value], %[mem]"
- : [value] "=r" (desired)
- : [mem] "m" (*p),
- "0" (desired)
- : "memory");
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement