This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH, VECTOR ABI] Add __attribute__((__simd__)) to GCC.
- From: Joseph Myers <joseph at codesourcery dot com>
- To: Kirill Yukhin <kirill dot yukhin at gmail dot com>
- Cc: Jeff Law <law at redhat dot com>, Jakub Jelinek <jakub at redhat dot com>, GCC Patches <gcc-patches at gcc dot gnu dot org>
- Date: Wed, 14 Oct 2015 13:40:42 +0000
- Subject: Re: [PATCH, VECTOR ABI] Add __attribute__((__simd__)) to GCC.
- Authentication-results: sourceware.org; auth=none
- References: <20151005130733 dot GB62312 at msticlxl57 dot ims dot intel dot com> <alpine dot DEB dot 2 dot 10 dot 1510051320120 dot 16355 at digraph dot polyomino dot org dot uk> <561551B0 dot 70507 at redhat dot com> <20151014123601 dot GA38813 at msticlxl57 dot ims dot intel dot com>
On Wed, 14 Oct 2015, Kirill Yukhin wrote:
> Is it ok for trunk?
This patch has no documentation. Documentation for new attributes must be
added to extend.texi.
> Enables creation of one or more versions that can process multiple
> arguments using SIMD instructions from a single invocation from a SIMD
> loop. It is ultimately an alias to `omp declare simdâ pragma, available
> w/o additional compiler switches. It is prohibited to use the attribute
> along with Cilk Plusâs `vectorâ attribute. If the attribute is specified
> and `pragma omp declare simdâ presents on a decl, then the attribute is
> ignored.
This is missing the key information that it's not just about *creation* of
the versions, it's about (in the case of an external declaration)
*assuming* such versions were created in another translation unit. And
you should have a link to the external ABI documents specifying for each
architecture for which this involves such an assumption exactly what
versions may be assumed to be present - this is what's required to be able
to use the attribute in headers for a library and know that future GCC
versions won't reinterpret the attribute as implying some versions for
future ISA extensions are also present.
I wonder whether the syntax for this attribute should allow optional
arguments to describe what versions are present, but maybe that can be
deferred until e.g. you want a way in future for a library to specify it
has an AVX1024 version of a function as well as the baseline ABI set of
versions.
--
Joseph S. Myers
joseph@codesourcery.com