[PATCH] Implement aarch64 neon instruction class AdvSIMD (by element) - Clang
t.p.northover at gmail.com
Mon Sep 30 02:31:57 PDT 2013
Comment at: utils/TableGen/NeonEmitter.cpp:1553-1554
@@ -1517,3 +1552,4 @@
+ case OpFMALane:
s += "__a + (__b * " + SplatLane(nElts, "__c", "__d") + ");";
Sorry, I should have spotted this earlier, but I think that an fma is semantically distinct from the C expression "a+b*c".
The latter we *can* transform into an fma in -ffast-math mode, but not generally. So we probably need an intrinsic to make sure that if the user asks for a fused multiply, that's the operation they get.
Actually, there'a already a generic llvm intrinsic to handle this: "@llvm.fma.*"; we should probably use that rather than an ARM/AArch64-specific one.
More information about the cfe-commits