gilgamash
Knight
Hi all fellow coders,
a short question, perhaps someone has some experience ( I do not have a good profiler atm to test it ): For a quick performing thread safe queue I implemented I need the nodes of the queue to be cache aligned to prevent false sharing. Any idea whether
a) Doing cache line padding
is quicker than
b) using gnu attribute
?
Thanks for help,
G.
a short question, perhaps someone has some experience ( I do not have a good profiler atm to test it ): For a quick performing thread safe queue I implemented I need the nodes of the queue to be cache aligned to prevent false sharing. Any idea whether
a) Doing cache line padding
is quicker than
b) using gnu attribute
Code:
__attribute__( (aligned(c_CachelineSize)) )
Thanks for help,
G.