------- Comment #14 from ubizjak at gmail dot com  2008-02-06 11:05 -------
We still generate:

.L8:
        movl    (%ebx), %eax
        addl    $1, %edx
        addl    $4, %ebx
        fldl    (%edi,%eax,8)
        fmull   (%ecx)
        addl    $8, %ecx
        cmpl    %edx, %esi
        faddp   %st, %st(1)
        jg      .L8

This could IMO be optimized on RTL level, to use %edx as a count variable:

.L8:
        movl    (%ebx,%edx,4), %eax
        fldl    (%edi,%eax,8)
        fmull   (%ecx,%edx,8)
        addl    $1, %edx
        cmpl    %edx, %esi
        faddp   %st, %st(1)
        jg      .L8

This would be optimal code for this loop.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21676

Reply via email to