<div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote">On Fri, Aug 7, 2015 at 1:00 PM, Daniel Berlin <span dir="ltr"><<a href="mailto:dberlin@dberlin.org" target="_blank">dberlin@dberlin.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class="">On Fri, Aug 7, 2015 at 12:45 PM, Matt Arsenault<br>
<<a href="mailto:Matthew.Arsenault@amd.com">Matthew.Arsenault@amd.com</a>> wrote:<br>
> On 08/07/2015 12:22 PM, Daniel Berlin via llvm-dev wrote:<br>
>><br>
>> Sorry to be pedantic, but i think it's important to make sure we are<br>
>> all on the same page that backends can't change the aliasing behavior<br>
>> of the default address space, only the aliasing behavior of the other<br>
>> address spaces.<br>
><br>
> Are you saying that we can't say address space 0 doesn't alias other address<br>
> spaces?<br>
<br>
</span>No.<br>
I'm saying "your target can't directly change what address space 0's<br>
aliasing properties are".<br>
<br>
So if you wanted to say "on NVPTX, address space 0 aliases *everything<br>
in the world, including everything in address space 0*", that is not<br>
okay.<br>
<br>
If they want to say "on NVPTX, all non-default address spaces alias<br>
everything in address space 0", that is fine.<br>
(Note: This does end up changing what alias queries return for<br>
pointers in different address spaces, but it has no effect on two<br>
pointers solely in address space 0)<br>
<br>
In practice, because you can change the properties *of the other<br>
address spaces*, and mayAlias is a symmetric relationship, it doesn't<br>
matter for this.<br>
<br>
But he wrote " For example,<br>
<span class="">>> in CUDA+NVPTX, addrspace(0) aliases everyone."<br>
<br>
</span>This is pedantically wrong. CUDA+NVPTX cannot and does not change the<br>
behavior of aliasing in address space 0, it changes the behavior of<br>
aliasing in all the other address spaces so that they alias pointers<br>
in address space 0 :P.<br></blockquote><div><br></div><div>Yes. We are on the same page. I was talking about whether two address spaces alias instead of pointers within the same address space aliasing. </div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
(As i said, it's really pedantic, but we need to be absolutely clear<br>
that targets do not control the properties of address space 0)<br>
</blockquote></div><br></div></div>