This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[i386, avx] add fma3 patterns


FMA3 aka AVX three-operand FMA.

Tested on x86_64-linux with the included asm scan tests.

HJ, I expect you'll be able to test on real hardware, 
though I expect any Real Tests will have to wait until
all the bits for auto-vectorization get added.  It seems
fairly hard to force all 3 insn alternatives to be 
generated...

Committed.


r~




        * config/i386/i386.c (bdesc_multi_arg): Use fma4i_fmadd_<mode>.
        * config/i386/sse.md (fma<mode>4): Enable for FMA & SSE_MATH.
        (fma4i_fmadd_<mode>): New.
        (*split_fma, *split_fms, *split_fnma, *split_fnms): Rename from
        fma4_fm*_<mode> and adjust to be pre-reload splitters to the 
        standard fma patterns.
        (fmaddsub_<mode>): Rename from fma4i_fmaddsub_<mode> and
        enable for FMA.
        (*fma_fmadd_<mode>, *fma_fmsub_<mode>): New.
        (*fma_fmadd_<mode>, *fma_fmsub_<mode>): New.
        (*fma_fmaddsub_<mode>, *fma_fmsubadd_<mode>): New.

testsuite/
        * gcc.target/i386/fma3-fma.c: New.
        * gcc.target/i386/fma3-builtin.c: New.
        * gcc.target/i386/fma4-builtin.c: New.

Attachment: z
Description: Text document


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]