[PATCH] D120570: [SVE] Add pattern to commute FMSB operands

Cameron McInally via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Mar 1 07:18:26 PST 2022


cameron.mcinally added inline comments.


================
Comment at: llvm/test/CodeGen/AArch64/sve-fp.ll:321-323
+  %neg = fneg <vscale x 8 x half> %b
+  %r = call <vscale x 8 x half> @llvm.fma.nxv8f16(<vscale x 8 x half> %a, <vscale x 8 x half> %neg, <vscale x 8 x half> %c)
+  ret <vscale x 8 x half> %r
----------------
paulwalker-arm wrote:
> paulwalker-arm wrote:
> > Can these tests treat the operands the same as the `fma` tests.  You're currently treating `%c` as the addend whereas the existing tests have this as `%a`.  The output will likely change to `fmls` instead of `fmsb` but that seems find to me. 
> I've just checked and these negated patterns are tested within `sve-fp-combine.ll` so I think that'll be a better home for your new tests.
I saw that file when I added the tests. The `sve-fp-combine.ll` tests all deal with FMUL+[FADD|FSUB] IR. There are no intrinsic tests in that file, so a little bit of a weird fit.

I don't have a preference on where these tests live though, so it's up to you...




CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D120570/new/

https://reviews.llvm.org/D120570



More information about the llvm-commits mailing list