MCPcopy Create free account
hub / github.com/MegEngine/MegEngine / fma

Method fma

dnn/include/megdnn/dtype/bfloat16.hpp:787–795  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

785 /// \param z third operand
786 /// \return \a x * \a y + \a z stored in single-precision
787 MEGDNN_HOST MEGDNN_DEVICE static expr fma(float x, float y, float z) {
788#if defined(__CUDA_ARCH__)
789 return expr(fmaf(x, y, z));
790#elif defined(FP_FAST_FMAF)
791 return expr(std::fma(x, y, z));
792#else
793 return expr(x * y + z);
794#endif
795 }
796
797 /// Get NaN.
798 /// \return bfloat16 quiet NaN

Callers

nothing calls this directly

Calls 2

exprClass · 0.70
fmaFunction · 0.70

Tested by

no test coverage detected