[llvm-bugs] [Bug 30753] New: Inefficient routines in altivec.h

via llvm-bugs llvm-bugs at lists.llvm.org
Thu Oct 20 18:59:15 PDT 2016


https://llvm.org/bugs/show_bug.cgi?id=30753

            Bug ID: 30753
           Summary: Inefficient routines in altivec.h
           Product: clang
           Version: trunk
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: normal
          Priority: P
         Component: -New Bugs
          Assignee: unassignedclangbugs at nondot.org
          Reporter: echristo at gmail.com
                CC: llvm-bugs at lists.llvm.org
    Classification: Unclassified

Code like:  

static __inline__ vector signed char __ATTRS_o_ai
vec_mergel(vector signed char __a, vector signed char __b) {
    return vec_perm(__a, __b,
                    (vector unsigned char)(0x08, 0x18, 0x09, 0x19, 0x0A, 0x1A,
                                           0x0B, 0x1B, 0x0C, 0x1C, 0x0D, 0x1D,
                                           0x0E, 0x1E, 0x0F, 0x1F));
}

which is using vec_perm isn't lowered very efficiently versus being lowered to
vmrglb. We should lower as many permutations to shuffles as possible and see
what we can do in the backend for more efficient code rather than hard coding
them though.

-- 
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/20161021/e869f324/attachment.html>


More information about the llvm-bugs mailing list