This is an archive of the discontinued LLVM Phabricator instance.

[DSE,MemorySSA] Handle atomic stores expliclty in isReadClobber.
ClosedPublic

Authored by fhahn on Sep 9 2020, 8:22 AM.

Details

Summary

Atomic stores are modeled as MemoryDef to model the fact that they may
not be reordered, depending on the ordering constraints.

Atomic stores that are monotonic or weaker do not limit re-ordering, so
we do not have to treat them as potential read clobbers.

Note that llvm/test/Transforms/DeadStoreElimination/MSSA/atomic.ll
already contains a set of negative test cases.

Diff Detail

Event Timeline

fhahn created this revision.Sep 9 2020, 8:22 AM
fhahn requested review of this revision.Sep 9 2020, 8:22 AM
This revision is now accepted and ready to land.Sep 9 2020, 11:19 AM
This revision was landed with ongoing or failed builds.Sep 9 2020, 3:02 PM
This revision was automatically updated to reflect the committed changes.