Thoughts on parallel programming?

retard re at tard.com.invalid
Thu Nov 11 13:38:30 PST 2010


Thu, 11 Nov 2010 16:32:03 -0500, bearophile wrote:

> Walter:
> 
>> Yup. I am bemused by the efforts put into analyzing loops so that they
>> can (by the compiler) be re-written into a higher level construct, and
>> then the higher level construct is compiled.
>> 
>> It just is backwards what the compiler should be doing. The high level
>> construct is what the programmer should be writing. It shouldn't be
>> something the compiler reconstructs from low level source code.
> 
> I agree a lot. The language has to offer means to express all the
> semantics and constraints, that the arrays are disjointed, that the
> operations done on them are pure or not pure, that the operations are
> not pure but determined only by a small window in the arrays, and so on
> and on. And then the compiler has to optimize the code according to the
> presence of SIMD registers, multi-cores, etc. This maybe is not enough
> for max performance applications, but in most situations it's plenty
> enough. (Incidentally, this is a lot what the Chapel language does (and
> D doesn't), and what I have explained in two past posts about Chapel,
> that were mostly ignored.)

How does the Chapel work when I need to sort data (just basic quicksort 
on 12 cores, for instance) or e.g. compile many files in parallel or 
encode xvid? What is the content of the array with xvid files?


More information about the Digitalmars-d mailing list