Am 13.07.2013 12:35, schrieb bearophile:
The resulting X86 asm:

__D4test12addParticlesFNaNbxS4test8ParticlexS4test8ParticleZS4test8Particle:

     pushl    %ebp
     movl    %esp, %ebp
     andl    $-16, %esp
     subl    $16, %esp
     movaps    40(%ebp), %xmm0
     movaps    56(%ebp), %xmm1
     addps    8(%ebp), %xmm0
     addps    24(%ebp), %xmm1
     movups    %xmm1, 16(%eax)
     movups    %xmm0, (%eax)

I think it would be more important if dmd would actually use the XMM registers correctly for computations. As you can see from the disassembly dmd generates code that always adds/moves from/to memory and does not stay within the registers at all.

http://d.puremagic.com/issues/show_bug.cgi?id=10226

Until dmd uses the XMM registers correctly it doesn't make much sense to add a special calling convetion for this purpose.

Kind Regards
Benjamin Thaut

Reply via email to