Add missing builtins to the PPC back end for ABI compliance (vol. 3)
authorNemanja Ivanovic <nemanja.i.ibm@gmail.com>
Fri, 10 Jul 2015 12:38:08 +0000 (12:38 +0000)
committerNemanja Ivanovic <nemanja.i.ibm@gmail.com>
Fri, 10 Jul 2015 12:38:08 +0000 (12:38 +0000)
This patch corresponds to review:
http://reviews.llvm.org/D10973

Back end portion of the third round of additions to altivec.h.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@241900 91177308-0d34-0410-b5e6-96231b3b80d8

include/llvm/IR/IntrinsicsPowerPC.td
lib/Target/PowerPC/PPCInstrVSX.td

index 630f89a0bddf72374cc95a0e7d1ebc4b11557a72..f708f803c05fa976cfabd1318123b97a7ea68347 100644 (file)
@@ -719,6 +719,9 @@ def int_ppc_vsx_xvcmpgtdp :
 def int_ppc_vsx_xvcmpgtsp :
       PowerPC_VSX_Intrinsic<"xvcmpgtsp", [llvm_v4i32_ty],
                             [llvm_v4f32_ty, llvm_v4f32_ty], [IntrNoMem]>;
+def int_ppc_vsx_xxleqv :
+      PowerPC_VSX_Intrinsic<"xxleqv", [llvm_v4i32_ty],
+                            [llvm_v4i32_ty, llvm_v4i32_ty], [IntrNoMem]>;
 }
 
 //===----------------------------------------------------------------------===//
index 3cb67deacbf720ba4d3c1598f9db693f9194f92e..544f69f978060c55dd8145cc112ca6c17ab2da9f 100644 (file)
@@ -1018,6 +1018,8 @@ let AddedComplexity = 400 in { // Prefer VSX patterns over non-VSX patterns.
                           [(set v4i32:$XT, (vnot_ppc (and v4i32:$XA,
                                                     v4i32:$XB)))]>;
   } // isCommutable
+  def : Pat<(int_ppc_vsx_xxleqv v4i32:$A, v4i32:$B),
+            (XXLEQV $A, $B)>;
 
   def XXLORC : XX3Form<60, 170,
                        (outs vsrc:$XT), (ins vsrc:$XA, vsrc:$XB),