[PATCH] D67552: [LangRef] Clarify fmuladd(a, b, c) can be treated as fadd (fmul a, b), c).
Florian Hahn via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Sep 13 07:38:23 PDT 2019
fhahn created this revision.
fhahn added reviewers: efriedma, jfb, reames, scanon, lebedev.ri, spatel.
Herald added a subscriber: dexonsmith.
Herald added a project: LLVM.
During the review of D67434 <https://reviews.llvm.org/D67434>, it was recommended to make fmuladd's
behavior more explicit. D67434 <https://reviews.llvm.org/D67434> depends on this interpretation.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D67552
Files:
llvm/docs/LangRef.rst
Index: llvm/docs/LangRef.rst
===================================================================
--- llvm/docs/LangRef.rst
+++ llvm/docs/LangRef.rst
@@ -13953,10 +13953,12 @@
is equivalent to the expression a \* b + c, except that rounding will
not be performed between the multiplication and addition steps if the
-code generator fuses the operations. Fusion is not guaranteed, even if
-the target platform supports it. If a fused multiply-add is required, the
-corresponding :ref:`llvm.fma <int_fma>` intrinsic function should be used
-instead. This never sets errno, just as '``llvm.fma.*``'.
+code generator fuses the operations. The optimizer can treat `@llvm.fmuladd`
+as `fadd (fmul %a, %b), %c`, until the code generator replaces it with
+a fused multiply-add. Fusion is not guaranteed, even if the target
+platform supports it. If a fused multiply-add is required, the corresponding
+:ref:`llvm.fma <int_fma>` intrinsic function should be used instead.
+This never sets errno, just as '``llvm.fma.*``'.
Examples:
"""""""""
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D67552.220099.patch
Type: text/x-patch
Size: 1040 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20190913/284e0c41/attachment.bin>
More information about the llvm-commits
mailing list