[LLVMbugs] [Bug 22413] New: New vector shuffle legality: turns movss (SSE2) or blendps (SSE4.2+) into shufps.

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Fri Jan 30 11:07:08 PST 2015


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

            Bug ID: 22413
           Summary: New vector shuffle legality: turns movss (SSE2) or
                    blendps (SSE4.2+) into shufps.
           Product: libraries
           Version: trunk
          Hardware: PC
                OS: All
            Status: NEW
          Severity: normal
          Priority: P
         Component: Backend: X86
          Assignee: unassignedbugs at nondot.org
          Reporter: ahmed.bougacha at gmail.com
                CC: llvmbugs at cs.uiuc.edu
    Classification: Unclassified

Created attachment 13785
  --> http://llvm.org/bugs/attachment.cgi?id=13785&action=edit
IR testcase

For the attached IR, we used to generate (for SSE2, but the AVX2 and SSE4.2
outputs are similarly interesting):

    movss    %xmm1, %xmm0
    shufps    $51, %xmm0, %xmm0       ## xmm0 = xmm0[3,0,3,0]
    movaps    %xmm0, (%rdi)

With the new all-shuffles-are-legal lowering, we now generate:

    shufps    $15, %xmm1, %xmm0       ## xmm0 = xmm0[3,3],xmm1[0,0]
    shufps    $216, %xmm0, %xmm0      ## xmm0 = xmm0[0,2,1,3]
    movaps    %xmm0, (%rdi)

The example is a bit harmless, so there's another, more interesting, one, in
the attached IR.

-- 
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/20150130/c268514b/attachment.html>


More information about the llvm-bugs mailing list