<div dir="ltr"><div class="gmail_extra">So, I don't have a horse in the OpenCL race, and I'd like to mostly keep it that way, but I want to point out that some of these things have much broader implications.</div><div class="gmail_extra">
<br><div class="gmail_quote">On Fri, Nov 8, 2013 at 11:45 PM, Matt Arsenault <span dir="ltr"><<a href="mailto:arsenm2@gmail.com" target="_blank" class="cremed">arsenm2@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
I don’t think think outright disallowing this transform is the right solution. This would be valid for OpenCL private or constant address spaces, it’s just global or local where this would be a problem.</blockquote><div><br>
</div><div>Unless I've misunderstood (which is a possibility, I've not invested proper time thinking about this, which I'll do if you indicate I'm missing something), this would be tantamount to tying certain address to specific rules regarding potential data races in the memory model. I'm not very comfortable with that. Perhaps you're instead trying to say that with certain address spaces "noalias" (and by inference, "restrict" at the language level) has a different semantic model than other address spaces? While it's less worrisome than the first interpretation, I still don't really like it.</div>
<div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">This comes back to the questions about how to handle address space alias information which there was a long thread about a few months ago. There was debate over address spaces as a language vs. a target concept, and I don’t remember right now what the consensuses were there.</blockquote>
</div><br>I think if OpenCL has special aliasing properties for specific address spaces it would make much more sense (IMO) to either have a specialized alias analysis that implements this, or to work out a proper metadata-based system for expressing these constraints from the frontend.</div>
</div>