rjmccall added a comment.

Okay.  I think I see your point about why it would be better to have a 
canonical __private address space that is different from the implicit address 
space 0.  I assume this means that there should basically never be pointers, 
references, or l-values in address space 0 in OpenCL.  You will lose a 
significant amount of representational efficiency by doing this, but it's 
probably not overwhelming.

I know you aren't implementing OpenCL C++ yet, so most of the cases where 
temporaries are introduced aren't meaningful to you, but you will at least need 
to consider compound literals.  I suspect the right rule is that file-scope 
literals should be inferred as being in __global or __constant memory, 
depending on whether they're const, and local-scope literals should be inferred 
as __private.

I'll try to review your patch tomorrow.


https://reviews.llvm.org/D35082



_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to