comp.lang.ada
 help / color / mirror / Atom feed
From: Georg Bauhaus <rm.dash-bauhaus@futureapps.de>
Subject: Q: GNAT and GCC variable/type attributes
Date: Mon, 12 Oct 2009 12:05:19 +0200
Date: 2009-10-12T12:05:29+02:00	[thread overview]
Message-ID: <4ad2ff69$0$6590$9b4e6d93@newsspool3.arcor-online.net> (raw)

GCC allows __attribute__ (...) to be applied to
variables, types, and functions.
Specifically, as explained in the GCC manual, ᅵ 5.45,
the "vector_size" attribute can be applied to
floating point types.  The effect is that variables
so declared can be used with SIMD instructions on Intel
or AMD CPUs.  Corresponding functions are built into
GCC, e.g.
http://gcc.gnu.org/onlinedocs/gcc/Vector-Extensions.html

GNAT does have a pragma Machine_Attribute (and pragma
Import (Intrinsic, ..., ...).  But naive use doesn't
have the desired effect: "vector_size" is rejected
as an Attribute_Name argument to the pragma.

Browsing the (surface of) GNAT sources, there seems
to be some support for this mechanism.  Does someone
know whether we might expect more of it in the future?



                 reply	other threads:[~2009-10-12 10:05 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox