This is an archive of the discontinued LLVM Phabricator instance.

[OMPIRBuilder] Fix store inst alignment for ordered depend directive
ClosedPublic

Authored by peixin on Dec 27 2021, 12:40 AM.

Diff Detail

Event Timeline

peixin created this revision.Dec 27 2021, 12:40 AM
peixin requested review of this revision.Dec 27 2021, 12:40 AM

Thanks for this patch @peixin. Can you please provide a reference to this requirement? (I was looking for the __kmpc_doacross_post in the RTL reference here but could not find it)

Thanks for this patch @peixin. Can you please provide a reference to this requirement? (I was looking for the __kmpc_doacross_post in the RTL reference here but could not find it)

I think it is the following.
https://github.com/llvm/llvm-project/blob/bde561c4813952847112600e5efe72d9015556f7/openmp/runtime/src/kmp_csupport.cpp#L4220
https://github.com/llvm/llvm-project/blob/df20599597079d620acb9ec2161fb54f838fbbb4/openmp/runtime/src/kmp.h#L4011

Thanks Kiran. The i64 vec change LGTM (I still didn't understand why the alignment has to be 8).

peixin added a comment.Jan 5 2022, 5:46 AM

Thanks Kiran. The i64 vec change LGTM (I still didn't understand why the alignment has to be 8).

Actually, the 4-byte alignment can also give correct running result. But the value is always stored with the type of integer 64, and the 8-byte alignment is more reasonable.

shraiysh accepted this revision.Jan 5 2022, 8:27 PM

LGTM.

This revision is now accepted and ready to land.Jan 5 2022, 8:27 PM

@kiranchandramohan Do you have further comments? If not, I will land this patch.

This revision was landed with ongoing or failed builds.Jan 13 2022, 5:48 PM
This revision was automatically updated to reflect the committed changes.