comp.lang.ada
 help / color / mirror / Atom feed
From: dennison@telepath.com (Ted Dennison)
Subject: Re: Ada and vectorization
Date: 18 Jun 2002 10:46:17 -0700
Date: 2002-06-18T17:46:19+00:00	[thread overview]
Message-ID: <4519e058.0206180946.2bbb9ac1@posting.google.com> (raw)
In-Reply-To: dstanbro-16FC0C.20004918062002@news-server.bigpond.net.au

Dale Stanbrough <dstanbro@bigpond.net.au> wrote in message news:<dstanbro-16FC0C.20004918062002@news-server.bigpond.net.au>...
> It would be nice if we let the compiler discover all of the possible
> vectorisations possible.  I've got no idea what the current state
> of the art is in this respect, however I would imagine that it would
> still be -cheaper- to build a simple compiler that took hints or 
> directions from the programmer about possible vectorisation.
> 
> Does anyone have real info instead of my speculation?
> 

I took a graduate-level compiler optimzation course a couple of years
ago that dealt almost entirely with this. Apparently most reasearch
done into compiler optimizations of this sort is done using Fortran,
as most of the folks who need that kind of number-cruching power have
Fortran code they want it done with.

Fortran's solution to this issue was to use the "hint" approach by
introducing new loop constructs (and a new dialect - HPF) for this. So
clearly they think it isn't feasable for normal Fortran. Actually, I
think the real issue may be that some operations will give different
results when done in parallel, and there has to be a way of saying
that's OK (or not OK) for your particular app.

So I really think the best way to do this in Ada would be via a pragma
on the loop name. The main drawback here is that if you put such code
through a compiler that doesn't support the pragma, then you may end
up with an incorrect calculation (in addition to a slower one).



  parent reply	other threads:[~2002-06-18 17:46 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-06-16  9:56 Ada and vectorization Guillaume Foliard
2002-06-16 12:50 ` Dale Stanbrough
2002-06-16 20:07   ` Matthias Kretschmer
2002-06-16 22:38     ` Robert A Duff
2002-06-18  8:24       ` Matthias Kretschmer
2002-06-18 10:02         ` Dale Stanbrough
2002-06-18 16:21           ` Matthias Kretschmer
2002-06-18 19:13             ` Robert A Duff
2002-06-18 20:12               ` Matthias Kretschmer
2002-06-18 20:51                 ` Guillaume Foliard
2002-06-19  4:28                   ` Matthias Kretschmer
2002-06-18 20:13             ` Guillaume Foliard
2002-06-18 17:46           ` Ted Dennison [this message]
2002-06-16 22:45   ` Ted Dennison
2002-06-17 23:47 ` Robert I. Eachus
replies disabled

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