You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
pyop3: compiled assignment in "inc" mode gives wrong values in parallel #5642
On more than one rank, an eager pyop3 assignment in "inc" mode with eager_strategy="compile" gives wrong values. The "array" strategy gives the right values.
array: 0 owned entries differ from 2
compile: 31 owned entries differ from 2
On 1 rank both strategies are correct. On 2 and 4 ranks the compile strategy gives 19 and 29 wrong owned entries. The lazy form f.dat.iassign(g.dat)() gives the same wrong values, and so does op3.loop(p := V.nodes.iter(), f.dat[p].iassign(g.dat[p]), eager=True).
The wrong entries are the owned entries that are ghost entries on other ranks. Each of them gets g once from its own rank and once more from every rank that holds it as a ghost, so its value is 2 plus the number of ghost copies. Before the halo exchange the ghost entries hold 0 + g, so the compiled assignment visits them as well, and the INC halo exchange then adds them to their owners.
Is "inc" meant to work for an assignment to a whole Dat with ghost entries? Or is INC only valid in a loop over owned entities?
An LLM (Claude Code) found this while I was digging into other pyop3 assignment work. G-ADOPT does not use this path but I am flagging it anyway.
Activity