Skip to content

Commit

Permalink
Add explicit failure parameter to CAS in the CUB attribute cache to w…
Browse files Browse the repository at this point in the history
…orkaround

a GCC 4.8 bug: https://godbolt.org/z/qmXYHc

Reviewed by: Michał 'Griwes' Dominiak <[email protected]>
  • Loading branch information
brycelelbach committed Apr 2, 2020
1 parent 35e4f69 commit f7ad39d
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion cub/util_device.cuh
Original file line number Diff line number Diff line change
Expand Up @@ -293,7 +293,8 @@ public:
// it by trying to set the state from `DeviceEntryReady` to
// `DeviceEntryInitializing`.
if (flag.compare_exchange_strong(old_status, DeviceEntryInitializing,
std::memory_order_acq_rel))
std::memory_order_acq_rel,
std::memory_order_acquire))
{
// We successfully set the state to `DeviceEntryInitializing`;
// we have the lock and it's our job to initialize this entry
Expand Down

0 comments on commit f7ad39d

Please sign in to comment.