[x86] add a convenience method to check for FMA capability; NFCI
[oota-llvm.git] / lib / Target / X86 / X86Subtarget.h
index eb0199aecbebd57bfa978a5505da8700f963b166..353b4f7f5ebdef060288903cf3289dff736e3d74 100644 (file)
@@ -358,6 +358,7 @@ public:
   // has equal or better performance on all supported targets.
   bool hasFMA() const { return HasFMA && !HasFMA4; }
   bool hasFMA4() const { return HasFMA4; }
+  bool hasAnyFMA() const { return hasFMA() || hasFMA4() || hasAVX512(); }
   bool hasXOP() const { return HasXOP; }
   bool hasTBM() const { return HasTBM; }
   bool hasMOVBE() const { return HasMOVBE; }