x86 sfence vs cache flush
Posted: Wed May 28, 2014 8:57 am
Code example:
mov [mem], eax
sfence
After sfence instruction is executed, the data in eax is written to cache or memory?
If it's written to memory, "cache flush" operation is NOT needed. Right?
If it's written to cache, how to do cache flush on x86?
This question is very important when a processor load some code to mem then execute the code.
mov [mem], eax
sfence
After sfence instruction is executed, the data in eax is written to cache or memory?
If it's written to memory, "cache flush" operation is NOT needed. Right?
If it's written to cache, how to do cache flush on x86?
This question is very important when a processor load some code to mem then execute the code.