Reputation: 402
I thought typically memory barriers can be categorized into four types. Some of the barriers include multiple functions. For example, StoreLoad can both prevent reordering between store and load, and drain the store buffer.
These two functions are seemingly irrelevant to each other, so I wonder why they are combined into one instruction. In other words, why do we not use two individual instructions, one for draining store buffer and another for preventing reordering?
I know there must be some intrinsic connection, but I cannot figure it out myself, so I posted this question. I appreciate any suggestions and guidance.
Upvotes: 1
Views: 89