Homec4science

fix race condition on rho

Authored by Dan Ibanez <dan.a.ibanez@gmail.com> on Jan 10 2017, 23:22.

Description

fix race condition on rho

the main bug here is the use of a local
rho_i accumulator which later gets assigned
back to rho[i].
in parallel, atomic additions can happen to
rho[i] while the local accumulator is held;
those atomic additions are lost when
the accumulator is atomically assigned.
we instead initialize the accumulator to zero
and atomically add it back to rho[i].

Details

Committed
Dan Ibanez <dan.a.ibanez@gmail.com>Jan 10 2017, 23:22
Pushed
jungeOct 19 2017, 09:53
Parents
rLAMMPS001964ecd8ac: Merge branch 'ibaned-pair-table-rx-inherit' into USER-DPD_kokkos
Branches
Unknown
Tags
Unknown

Event Timeline

Dan Ibanez <dan.a.ibanez@gmail.com> committed rLAMMPSd26f1403cdb7: fix race condition on rho (authored by Dan Ibanez <dan.a.ibanez@gmail.com>).Jan 10 2017, 23:22