[PATCH][AVX512] FMA masking instruction variants and intrinsics

Adam Nemet anemet at apple.com
Tue Aug 12 13:36:06 PDT 2014


Hi,

Elena made the comment regarding the FMA intrinsics earlier to try to only expose the masking versions as intrinsics rather than having two sets of the intrinsics (masking, unconditional: with an all-one mask).  These changes implement that.

The flow of the patchset is to first adjust the masking base class to accommodate the FMA instruction and then add the variants.  We also need to rename the existing intrinsics to masking and provide the lowering.

Along the way there are some cleanup and refactoring patches as well.  Hopefully this should be clear from the log in the individual patch files.

As the last patch, I’ve included the intrinsic header diff I am planning to commit in CFE.  I followed the existing precedence set by AVX to use the LLVM intrinsic for nmadd rather than negate the first operand and fall back on the madd intrinsic.  We can also change that later if that seems more appropriate assuming of course that codegen will recover the nmadd.

Thanks and please let me know if it looks good.

Adam
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-AVX512-Add-masking-variant-for-the-FMA-instructions.patch
Type: application/octet-stream
Size: 13086 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20140812/bb1b96a4/attachment.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0002-AVX512-Break-out-the-logic-to-lower-masking-intrinsi.patch
Type: application/octet-stream
Size: 3156 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20140812/bb1b96a4/attachment-0001.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0003-AVX512-Add-enum-for-the-static-rounding-types.patch
Type: application/octet-stream
Size: 1944 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20140812/bb1b96a4/attachment-0002.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0004-X86-Break-out-logic-to-map-FMA-Intrinsic-number-to-O.patch
Type: application/octet-stream
Size: 5475 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20140812/bb1b96a4/attachment-0003.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0005-AVX512-Switch-FMA-intrinsics-to-the-masking-version.patch
Type: application/octet-stream
Size: 22061 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20140812/bb1b96a4/attachment-0004.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0006-AVX512-Add-test-for-FMA-masking-instrinsics.patch
Type: application/octet-stream
Size: 2033 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20140812/bb1b96a4/attachment-0005.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0007-clang-AVX512-Add-FMA-intrinsics.patch
Type: application/octet-stream
Size: 5096 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20140812/bb1b96a4/attachment-0006.obj>


More information about the llvm-commits mailing list