Back in the game: Numerics in D
FeepingCreature
default_357-line at yahoo.de
Sat Feb 20 11:27:01 PST 2010
On 20.02.2010 20:13, Norbert Nemec wrote:
> Hi there,
>
> just to say "Hi" to those that might still remember my name from the
> good ol' times. (I just checked - I actually sent 464 messages to this
> list from 2004 to 2006 and none since.)
>
I don't think I remember you! But I'll say welcome back anyway.
If you're interested in high-performance numerical computing, the current gdc has some hairy bugs that only show themselves on -O3 -ffast-math -march=native. Certainly enough to keep people on their toes :) Just keep it in mind - numerical errors may not actually be your fault.
Also, here's a copy of the GDC autovectorization patch: http://pastebin.com/f1c5b28df
It basically does the following: if you have a (simple) loop with index size four or two or whatever your mmx or sse step size is, it translates it into SSE expressions.
Example:
float[4] a, b, c; [...]
for (int i = 0; i < 4; ++i) a[i] = b[i] + c[i]; // addps
You can observe the process by passing -ftree-vectorizer-verbose=9 2>&1 |less to gdc (or gdc-build, which I've found handy for full custom rebuilds: http://pastebin.com/f28310a8a ).
Good luck with the numerical work and, welcome back to D. Have fun!
More information about the Digitalmars-d
mailing list