Why am I getting cache miss while accessing a variable, only updated by the same thread?
I am trying to measure cache misses in a multi-threaded application using perf_event_open on Linux. The code involves two threads: Thread t1, that updates an aligned integer (x) and another thread t2 reads from it. However, I am getting cache misses on accessing x with thread t1, even though it is only updated by t1 only.