[llvm-bugs] [Bug 26460] New: int3 __builtin_astype(x, short8) asserts for OpenCL
via llvm-bugs
llvm-bugs at lists.llvm.org
Wed Feb 3 13:17:21 PST 2016
https://llvm.org/bugs/show_bug.cgi?id=26460
Bug ID: 26460
Summary: int3 __builtin_astype(x, short8) asserts for OpenCL
Product: clang
Version: unspecified
Hardware: PC
OS: Windows NT
Status: NEW
Severity: normal
Priority: P
Component: LLVM Codegen
Assignee: unassignedclangbugs at nondot.org
Reporter: pjcoup at gmail.com
CC: llvm-bugs at lists.llvm.org
Classification: Unclassified
For this file:
typedef int int3 __attribute__((ext_vector_type(3)));
typedef short short8 __attribute((ext_vector_type(8)));
int get(short8 x) {
int3 y = __builtin_astype(x, int3);
return y[0];
}
clang -S -emit-llvm -x cl hits the following assert:
/home/peter/llvm/llvm-trunk-git/llvm/lib/IR/Instructions.cpp:2572: static
llvm::CastInst* llvm::CastInst::Create(llvm::Instruction::CastOps,
llvm::Value*, llvm::Type*, const llvm::Twine&, llvm::Instruction*): Assertion
`castIsValid(op, S, Ty) && "Invalid cast!"' failed.
int3 <-> int4 __builtin_astype works, as does short8 <-> int4.
--
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/20160203/4ff0d0b7/attachment.html>
More information about the llvm-bugs
mailing list