[llvm-bugs] [Bug 33212] New: PPC vec_cst useless at -O0

via llvm-bugs llvm-bugs at lists.llvm.org
Mon May 29 14:14:33 PDT 2017


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

            Bug ID: 33212
           Summary: PPC vec_cst useless at -O0
           Product: libraries
           Version: trunk
          Hardware: PC
                OS: All
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: Backend: PowerPC
          Assignee: unassignedbugs at nondot.org
          Reporter: benny.kra at gmail.com
                CC: echristo at gmail.com, llvm-bugs at lists.llvm.org,
                    timshen91 at gmail.com

$ cat cts.cc
#include <altivec.h>

typedef __vector float Packet4f;
typedef __vector int Packet4i;

Packet4i ConvertToPacket4i(const Packet4f& x) { return vec_cts(x, 0); }

$ clang --target=powerpc64le-linux-gnu cts.cc
fatal error: error in backend: Cannot select: intrinsic
%llvm.ppc.altivec.vctsxs

A workaround would be using macros instead of inline functions.

-- 
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/20170529/b7b56e21/attachment.html>


More information about the llvm-bugs mailing list