Why I chose D over Ada and Eiffel
John Colvin
john.loughran.colvin at gmail.com
Thu Aug 22 03:34:56 PDT 2013
On Thursday, 22 August 2013 at 02:06:13 UTC, Tyler Jameson Little
wrote:
> - array operations (int[] a; int[]b; auto c = a * b;)
> - I don't think these are automagically SIMD'd, but there's
> always hope =D
That isn't allowed. The memory for c must be pre-allocated, and
the expression then becomes c[] = a[] * b[];
Is it SIMD'd?
It depends. There is a whole load of hand-written assembler for
simple-ish expressions on builtin types, on x86. x86_64 is only
supported with 32bit integer types because I haven't finished
writing the rest yet...
However, I'm not inclined to do so at the moment as we need a
complete overhaul of that system anyway as it's currently a
monster*. It needs to be re-implemented as a template
instantiated by the compiler, using core.simd. Unfortunately it's
not a priority for anyone right now AFAIK.
*
hand-written asm loops. If fully fleshed out there would be:
((aligned + unaligned + legacy mmx) * (x86 + x64) + fallback
loop)
* number of supported expressions * number of different types
of them. Then there's unrolling considerations. See
druntime/src/rt/arrayInt.d
More information about the Digitalmars-d
mailing list