[llvm-bugs] [Bug 44294] New: The address space is not printed correctly in function parameters
via llvm-bugs
llvm-bugs at lists.llvm.org
Fri Dec 13 05:14:40 PST 2019
https://bugs.llvm.org/show_bug.cgi?id=44294
Bug ID: 44294
Summary: The address space is not printed correctly in function
parameters
Product: clang
Version: trunk
Hardware: PC
OS: Linux
Status: NEW
Severity: enhancement
Priority: P
Component: OpenCL
Assignee: unassignedclangbugs at nondot.org
Reporter: anastasia.stulova at arm.com
CC: anastasia.stulova at arm.com, llvm-bugs at lists.llvm.org
Clang looses information about address space of function parameters in some
cases. See examples from review:
https://reviews.llvm.org/D71272#inline-646266
void myRead(read_only image1d_t);
typedef write_only image1d_t img1d_wo;
kernel void k1(img1d_wo img) {
myRead(img); // expected-error {{passing '__private img1d_wo' (aka '__private
__write_only image1d_t') to parameter of incompatible type '__read_only
image1d_t'}}
}
or
void f_gen(__generic int *arg_gen) {}
void f(){
__constant int *var_sub;
f_gen(var_sub); // expected-error {{passing '__constant int *__private' to
parameter of type '__generic int *' changes address space of pointer}}
}
'__private' is not printed in the second type in both cases.
--
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/20191213/20dc87cb/attachment-0001.html>
More information about the llvm-bugs
mailing list