[LLVMbugs] [Bug 21139] New: New vector shuffle lowering misses to use punpckhbw

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Thu Oct 2 13:17:07 PDT 2014


http://llvm.org/bugs/show_bug.cgi?id=21139

            Bug ID: 21139
           Summary: New vector shuffle lowering misses to use punpckhbw
           Product: libraries
           Version: trunk
          Hardware: PC
                OS: All
            Status: NEW
          Severity: normal
          Priority: P
         Component: Backend: X86
          Assignee: unassignedbugs at nondot.org
          Reporter: qcolombet at apple.com
                CC: llvmbugs at cs.uiuc.edu
    Classification: Unclassified

Created attachment 13123
  --> http://llvm.org/bugs/attachment.cgi?id=13123&action=edit
IR to reproduce the problem.

With the new vector shuffle lowering we produce a sequence of a shuffle +
unpckl instead of a more direct unpckh.

To reproduce:
llc -x86-experimental-vector-shuffle-lowering=true none_shuf_unpckl_unpckh.ll
-o new.s
llc -x86-experimental-vector-shuffle-lowering=false none_shuf_unpckl_unpckh.ll
-o old.s

diff -U 10 old.s new.s

 _foo:                                   ## @foo
     .cfi_startproc
 ## BB#0:                                ## %entry
+    pshufd    $78, %xmm1, %xmm1       ## xmm1 = xmm1[2,3,0,1]
     pxor    %xmm0, %xmm0
-    punpckhbw    %xmm1, %xmm0    ## xmm0 =
xmm0[8],xmm1[8],xmm0[9],xmm1[9],xmm0[10],xmm1[10],xmm0[11],xmm1[11],xmm0[12],xmm1[12],xmm0[13],xmm1[13],xmm0[14],xmm1[14],xmm0[15],xmm1[15]
+    punpcklbw    %xmm1, %xmm0    ## xmm0 =
xmm0[0],xmm1[0],xmm0[1],xmm1[1],xmm0[2],xmm1[2],xmm0[3],xmm1[3],xmm0[4],xmm1[4],xmm0[5],xmm1[5],xmm0[6],xmm1[6],xmm0[7],xmm1[7]
     retq

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20141002/d26f649a/attachment.html>


More information about the llvm-bugs mailing list