You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
From slide 30:
"Assertion failure due to reordering in the left thread or in the right thread"
In the case of the left thread reordering, I can see why assertion fails(1)FLAG.store(1); 2)right thread 3)DATA = 42;). However, I cannot imagine how the right thread should be reordered in order for the assertion to fail?
Thank you!
The text was updated successfully, but these errors were encountered:
Does this mean that assert(DATA) == 42 can be executed irrespectively of the condition of FLAG.load()? Doesn't this kind of reordering break the logic of the program, and thus shouldn't be allowed by the compiler?
From slide 30:
![Screen Shot 2019-10-12 at 16 55 26](https://user-images.githubusercontent.com/38908309/66697507-2e635700-ed11-11e9-8341-291be6b73598.png)
"Assertion failure due to reordering in the left thread or in the right thread"
In the case of the left thread reordering, I can see why assertion fails(1)FLAG.store(1); 2)right thread 3)DATA = 42;). However, I cannot imagine how the right thread should be reordered in order for the assertion to fail?
Thank you!
The text was updated successfully, but these errors were encountered: