aboutsummaryrefslogtreecommitdiff
path: root/fb3f36cec108ce9c55241d9f0e66d4832a552b8a
diff options
context:
space:
mode:
authorBrian Brooks <brian.brooks@arm.com>2017-08-26 00:40:08 -0500
committerMaxim Uvarov <maxim.uvarov@linaro.org>2017-09-21 23:20:02 +0300
commitc2ed3f71a8d61449c5e35ce201f020a74a8ea244 (patch)
tree67855c4ec799422ca2f815aa5f24d33e61525687 /fb3f36cec108ce9c55241d9f0e66d4832a552b8a
parentcbb7f52e28d2e1c20c8eac662aa6135242d072e8 (diff)
downloadodp-master.tar.gz
linux-gen: barrier: Use correct memory orderingHEADmaster
Memory accesses that happen-before, in program order, a call to odp_barrier_wait() cannot be reordered to after the call. Similarly, memory accesses that happen-after, in program order, a call to odp_barrier_wait() cannot be reordered to before the call. The current implementation of barriers uses sequentially consistent fences on either side of odp_barrier_wait(). The correct memory ordering for barriers is release upon entering odp_barrier_wait(), to prevent reordering to after the barrier, and acquire upon exiting odp_barrier_wait(), to prevent reordering to before the barrier. The measurable performance difference is negligible on weakly ordered architectures such as ARM, so the highlight of this change is correctness. Signed-off-by: Brian Brooks <brian.brooks@arm.com> Reviewed-by: Bill Fischofer <bill.fischofer@linaro.org> Signed-off-by: Maxim Uvarov <maxim.uvarov@linaro.org>
Diffstat (limited to 'fb3f36cec108ce9c55241d9f0e66d4832a552b8a')
0 files changed, 0 insertions, 0 deletions