struct node* address; //format <addr,flagBit1,flagBit2>
I want to use BTS to atomically set the flagBit1
bit.
EDIT
I want to blindly set this bit without caring about if it was previously set or not
I can use assembly code to get this done as suggested in Using bts assembly instruction with gcc compiler
But is there an intrinsic I can use which is portable across different architectures?
For instance, gcc Atomic Builtins has __sync_fetch_and_or
. Does this have the same property as BTS?