3D Math Data structures/SIMD

Don Clugston dac at nospam.com.au
Sat Dec 22 01:57:55 PST 2007


Lukas Pinkowski wrote:
> Jascha Wetzel wrote:
>> this has been proposed before and there has been discussion about the
>> naming, too. i'd like to see that rather sooner than later, as well.
> 
> I think GDC and LLVMDC would be nice testbeds for such an extension. One of
> these could implement those into the compiler along with a software
> implementation for compatibility with the other compilers. Hopefully Walter
> would either include this experimental extension into the D spec, or
> propose a standard interface himself.
> I overlooked the LLVM tutorial and it seems to be quite easy, but I don't
> whether I find the time soon to do myself what I demand from others ;-)
>  
>> you might want to check out Don Clugston's work on Blade, which is a
>> significant step towards what you're looking for.
> 
> I know about it, and it's really awesome what you can do in D.
> 
Do you think you could come up with some concrete examples?
I could imagine a version specialised for 2-D and 3-D vectors and quaternions.
Something like:
---
import blade.ginsu;

float[4][] f, g;
const float K = 1.234;

mixin(ginsu(q{
f[5..60].x = g[0..55].y + g[2..57].z;
// whatever else
});

---
I'm not a game programmer, so I don't really have much idea of which operations 
are important.
It would be really helpful to have some example inner loops.



More information about the Digitalmars-d mailing list