tmp->data2 = prev->data2 + d2;
tmp->data3 = prev->data3 + d3;
succ = data.compare_exchange_strong(prev, tmp,
- memory_order_acq_rel, memory_order_relaxed);
+ memory_order_release, memory_order_acquire);
/**
@Begin
@Commit_point_define_check: succ
thrd_create(&t1, threadA, NULL);
thrd_create(&t2, threadB, NULL);
- thrd_create(&t3, threadC, NULL);
- thrd_create(&t4, threadD, NULL);
+ //thrd_create(&t3, threadC, NULL);
+ //thrd_create(&t4, threadD, NULL);
thrd_join(t1);
thrd_join(t2);
- thrd_join(t3);
- thrd_join(t4);
+ //thrd_join(t3);
+ //thrd_join(t4);
return 0;
}