<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On Sun, May 18, 2014 at 6:50 PM, Rafael Espíndola <span dir="ltr"><<a href="mailto:rafael.espindola@gmail.com" target="_blank">rafael.espindola@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">This patch completes the implementation of pr10367. With it an alias<br>
can reliably<br>
point to an offset of another object.<br>
<br>
This is needed for RTTI on windows where the RTTI data precedes the<br>
vtable symbol. It also seems desirable for concatenating globals used<br>
from a single function to improve ARM and AARCH64 code.<br>
<br>
Particular items it would be nice to have a second opinion on:<br>
<br>
* LL Syntax<br>
* Bitcode representation<br></blockquote><div><br></div><div>Seems fine. I think we've essentially settled on the raw offset rather than a GEP, and everything follows from that.</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
* I included tests for llvm-as/llvm-dis, llvm-link and llc, but let me<br>
know if there is any other test you would find interesting.<br></blockquote><div><br></div><div>Doesn't LLVM have optimizations that replace uses of an alias with uses of the global? I'm surprised this didn't require those kinds of changes. Are you deferring optimizer changes for the moment?</div>
<div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
* Should offsets past the end of an object be illegal or we just don't<br>
define what the result is?<br></blockquote><div><br></div><div>I think it's fine to allow them. It's the same as GEPing past the end of the object. Later someone could GEP back and do loads and stores through that.</div>
</div></div></div>