1*f504f610SAugustin Cavalier #include <math.h> 2*f504f610SAugustin Cavalier 3*f504f610SAugustin Cavalier #if __ARM_FEATURE_FMA && __ARM_FP&8 && !__SOFTFP__ 4*f504f610SAugustin Cavalier fma(double x,double y,double z)5*f504f610SAugustin Cavalierdouble fma(double x, double y, double z) 6*f504f610SAugustin Cavalier { 7*f504f610SAugustin Cavalier __asm__ ("vfma.f64 %P0, %P1, %P2" : "+w"(z) : "w"(x), "w"(y)); 8*f504f610SAugustin Cavalier return z; 9*f504f610SAugustin Cavalier } 10*f504f610SAugustin Cavalier 11*f504f610SAugustin Cavalier #else 12*f504f610SAugustin Cavalier 13*f504f610SAugustin Cavalier #include "../fma.c" 14*f504f610SAugustin Cavalier 15*f504f610SAugustin Cavalier #endif 16