diff --git a/lib/Target/ARM/ARMInstrInfo.td b/lib/Target/ARM/ARMInstrInfo.td index ca3d1c2aecb..099b499c52a 100644 --- a/lib/Target/ARM/ARMInstrInfo.td +++ b/lib/Target/ARM/ARMInstrInfo.td @@ -276,7 +276,8 @@ def FNEGD : InstARM<(ops DFPRegs:$dst, DFPRegs:$src), def FMULS : FPBinOp<"fmuls", fmul>; def FMULD : DFPBinOp<"fmuld", fmul>; - +def FDIVS : FPBinOp<"fdivs", fdiv>; +def FDIVD : DFPBinOp<"fdivd", fdiv>; // Floating Point Load def FLDS : InstARM<(ops FPRegs:$dst, IntRegs:$addr), diff --git a/test/CodeGen/ARM/fparith.ll b/test/CodeGen/ARM/fparith.ll index c72a8738735..f83aa771dbf 100644 --- a/test/CodeGen/ARM/fparith.ll +++ b/test/CodeGen/ARM/fparith.ll @@ -4,7 +4,9 @@ ; RUN: llvm-as < %s | llc -march=arm | grep fmuls && ; RUN: llvm-as < %s | llc -march=arm | grep fmuld && ; RUN: llvm-as < %s | llc -march=arm | grep fnegs && -; RUN: llvm-as < %s | llc -march=arm | grep fnegd +; RUN: llvm-as < %s | llc -march=arm | grep fnegd && +; RUN: llvm-as < %s | llc -march=arm | grep fdivs && +; RUN: llvm-as < %s | llc -march=arm | grep fdivd float %f1(float %a, float %b) { entry: @@ -53,3 +55,15 @@ entry: %tmp1 = sub double -0.000000e+00, %a ret double %tmp1 } + +float %f9(float %a, float %b) { +entry: + %tmp1 = div float %a, %b + ret float %tmp1 +} + +double %f10(double %a, double %b) { +entry: + %tmp1 = div double %a, %b + ret double %tmp1 +}