[fpc-pascal] Common OpenMP syntax?
JeLlyFish.software at gmx.net
Wed Jul 26 11:26:38 CEST 2006
On Wednesday 26 July 2006 09:00, Michael Van Canneyt wrote:
> On Wed, 26 Jul 2006, Vinzent Hoefler wrote:
> > On Wednesday 26 July 2006 08:17, Micha Nelissen wrote:
> > > Vinzent Hoefler wrote:
> > > > Well, I just added some stuff there, yesterday. It's far from
> > > > being complete yet (it just covers a basic "parallel"
> > > > construct), nor is it really thought through yet, but well, it
> > > > might be a start; something to begin with.
> > > >
> > > > Any suggestions are welcome, of course.
> > >
> > > Does parallel mean all the statements in the block can be
> > > executed in parallel, or that multiple copies of the block of
> > > statements can be started in parallel ?
> > The latter.
> Which is why I think that it's better to have them as local
> functions, instead of having to introduce a lot of new functions.
Hey, it's only *one* new keyword yet. :)
Admitted, local blocks are more Adaish, but with this approach, I was
trying to avoid introducing a lot more keywords. There still probably
will be some, because there are more constructs like "barrier",
"workshare" (which I didn't fully understand yet) and "section".
And well, such blocks are already known in Object Pascal. Just look at
them as in object declarations the public/protected/private modifiers.
> Local functions are very pascal-ish. C doesn't have it, which is why
> they can't use it. Let's use the language features to their full
Yes. I agree with that. The problem is that there are more "variable"
types than just shared and private (like "firstprivate"), so it might
prove to be quite difficult to do that if you only have local
functions. I just didn't come to that part yet.
I'll probably update the WiKi this evening/night (can't do that from
work, where freepascal.org still times out).
More information about the fpc-pascal