Now
MAIN commitmail json YAML
RCU pointer fixes.
- Use __typeof__, not typeof.
- Use membar_exit, not membar_producer.
=> We want a store-release, not store/store barrier.
=> Consider:
foo->x = 42;
assert(foo->x == 42);
rcu_assign_pointer(globalfoo, foo);
The foo->x load can be reordered past the store/store barrier
(membar_producer), and happen after another thread has clobbered
foo->x.
- Put the evaluation of the right-hand side before the barrier.
- Use __typeof__, not typeof.
- Use membar_exit, not membar_producer.
=> We want a store-release, not store/store barrier.
=> Consider:
foo->x = 42;
assert(foo->x == 42);
rcu_assign_pointer(globalfoo, foo);
The foo->x load can be reordered past the store/store barrier
(membar_producer), and happen after another thread has clobbered
foo->x.
- Put the evaluation of the right-hand side before the barrier.