Changes

Jump to: navigation, search

GPU621/Analyzing False Sharing

405 bytes added, 16:47, 24 November 2022
no edit summary
We can notice that the time taken for multiple executions is significantly more stable and shorter than before.
 
Let's take another look at what happens when O2 is turned on.
 
g++ -std=c++11 -pthread -O2 false_sharing.cpp
 
After running it, I found that the difference between the runtime with and without byte alignment is very small and there is no instability, the runtime is around 200ms.
 
But the unexpected thing is that when I execute increment1() and increment2() in serial code only, it only consumes 53ms!
118
edits

Navigation menu