[ET Trac] #2832: possible race condition in LoopControl
Erik Schnetter
trac-noreply at einsteintoolkit.org
Tue Nov 5 09:51:52 CST 2024
#2832: possible race condition in LoopControl
Reporter: Roland Haas
Status: new
Milestone:
Version:
Type: bug
Priority: major
Component:
Comment (by Erik Schnetter):
As you say, your padding doesn’t actually align the struct. The struct may thus be split across two cache lines. Since some architectures have 128-byte cache lines, you should instead pad to 2\*128 bytes. \(Intel CPUs have 64-byte cache lines and thus 128 bytes suffice there.\)
You can instead also check the alignment \(see [https://en.cppreference.com/w/c/language/\_Alignof](https://en.cppreference.com/w/c/language/_Alignof)\) with a static assertion.
--
Ticket URL: https://bitbucket.org/einsteintoolkit/tickets/issues/2832/possible-race-condition-in-loopcontrol
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.einsteintoolkit.org/pipermail/trac/attachments/20241105/2198c60e/attachment-0001.htm>
More information about the Trac
mailing list