From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,2ac7208e3d69354f X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2002-06-16 05:50:27 PST Path: archiver1.google.com!news1.google.com!newsfeed.stanford.edu!newsfeeds.belnet.be!news.belnet.be!deine.net!intgwpad.nntp.telstra.net!news.telstra.net!news-server.bigpond.net.au!not-for-mail From: Dale Stanbrough Newsgroups: comp.lang.ada Subject: Re: Ada and vectorization References: User-Agent: MT-NewsWatcher/3.2 (PPC Mac OS X) Message-ID: Date: Sun, 16 Jun 2002 12:50:23 GMT NNTP-Posting-Host: 144.132.91.90 X-Complaints-To: news@bigpond.net.au X-Trace: news-server.bigpond.net.au 1024231823 144.132.91.90 (Sun, 16 Jun 2002 22:50:23 EST) NNTP-Posting-Date: Sun, 16 Jun 2002 22:50:23 EST Organization: BigPond Internet Services (http://www.bigpond.net.au) Xref: archiver1.google.com comp.lang.ada:26077 Date: 2002-06-16T12:50:23+00:00 List-Id: Guillaume Foliard wrote: > Hello, > > I start to learn how to use the Intel's SSE instruction set in Ada programs > with inline assembly. And while reading Intel documentation (1) I was > asking myself if Ada could provide a clean way of vectorization through its > strong-typed approach. Could it be sensible, for the next Ada revision, to > create some new attributes for array types to explicitly hint the compiler > that we want to use SIMD instructions ? > Language lawyers comments are definitly welcome. As SIMD in modern general > purpose processors is largely available nowadays (SSE, SSE2, Altivec, > etc...), IMHO, it would be a mistake for Ada to ignore the performance > benefit this could bring. I think the best way to do this is via pragmas. There is one pragma - Annotate - which would be perfect for the job. I think Annotate is a Gnat only thing - the real work would have to be done with an ASIS like tool. Very much like the fortran world, where the structured comments can be ignored by ignorant compilers, and the program still behaves correctly (if not as fast). Dale