On Tue, Sep 26, 2023 at 09:34:15AM +0200, Richard Biener wrote: > On Mon, Sep 25, 2023 at 8:25 PM Tobias Burnus <tob...@codesourcery.com> wrote: > > > > I stumbled over this during the ARM64 talk at the cauldron as they > > consider using -fopenmp-simd by default. > > Ah, forgot to ask during the talk - isn't __attribute__((simd(..))) exactly to > avoid the need for -fopenmp-simd?
Yes. Though, -fopenmp-simd can do slightly more than that, #pragma GCC ivdep equivalent on various loops is the other important part (though for both simd attribute and ivdep pragma the OpenMP counterparts are significantly more flexible, in the declare simd case one can specify certain arguments should be linear (with various variants for references)/uniform, simd construct can specify not just everything is independent or not, but how many consecutive iterations must be independent, can specify reductions etc., preferred vectorization factors, ...). Though, I don't think it is a good idea to enable -fopenmp-simd by default. Jakub