On Wed, Aug 12, 2020 at 04:55:03PM +0200, Tobias Burnus wrote:
> Low-hanging fruit: Add support for 'omp simd's nontemporal clause,
> which is part of the OpenMP 5.0 features suppored by the ME + C/C++.

To be precise, the ME just ignores it.
While GIMPLE has support for gimple_assign_nontemporal_move_p assignments,
neither omp-low nor omp-expand actually does attempt to set those on
accesses to variables with that clause, and it is e.g. unclear if it is a
safe thing to do.  Don't non-temporal stores e.g. bypass caches on some
architectures, so if e.g. there are stores to those variables shortly before
or after the simd region, won't that make it unclear what values will
appear?  Or do we e.g. need to add some memory barrier instruction at the
start and/or end of the region?  What about non-direct accesses to the
variables?  E.g. if we shouldn't punt if they are address taken etc.
Or would it need to be preserved in the middle-end somehow and resolved
after IPA so that e.g. C++ abstraction would be optimized away where
possible?

Your patch LGTM though.

        Jakub

Reply via email to