The data access is not sufficiently protected against a reordering with read_position. While there is a AqcRel fence, the fence has no counterpart to synchronize with. This can be fixed by replacing the fence with a store on read_position with Ordering::Release in pop and a load with Ordering::Acquire in push.
Expected result or behaviour:
The data array is protected against reordering.
Conditions where it occurred / Performed steps:
It can happen whenever the CPU reorders the instructions.
Required information
Operating system: all
Rust version: all
Cargo version: all
iceoryx2 version:
main
branchObserved result or behaviour:
The
data
access is not sufficiently protected against a reordering withread_position
. While there is aAqcRel
fence, the fence has no counterpart to synchronize with. This can be fixed by replacing the fence with a store onread_position
withOrdering::Release
inpop
and a load withOrdering::Acquire
inpush
.Expected result or behaviour:
The
data
array is protected against reordering.Conditions where it occurred / Performed steps:
It can happen whenever the CPU reorders the instructions.