<div dir="ltr"><div>Errr, this is not two GEPS of a struct type base pointer with the same type, with a minimum of two operands, etc.</div><div><br></div><div>It's</div><div>  %6 = getelementptr inbounds i8, i8* %5, i64 %4</div><div>   %9 = getelementptr inbounds %struct.A, %struct.A* %x, i32 0, i32 1<br></div><div><br></div><div>This code will do nothing with this.</div><div><br></div><div>Want to try again?<br>:)</div><div><br></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Jun 1, 2016 at 5:49 PM, Eli Friedman <span dir="ltr"><<a href="mailto:eli.friedman@gmail.com" target="_blank">eli.friedman@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">eli.friedman added a comment.<br>
<br>
Example:<br>
<br>
  struct A {<br>
    unsigned char a[10];<br>
    unsigned char b;<br>
  };<br>
  void f(A* x) {<br>
    for (unsigned i = 0; i < 11; ++i)<br>
      x->b += ((unsigned char*)x)[i];<br>
<div class="HOEnZb"><div class="h5">  }<br>
<br>
<br>
Repository:<br>
  rL LLVM<br>
<br>
<a href="http://reviews.llvm.org/D20665" rel="noreferrer" target="_blank">http://reviews.llvm.org/D20665</a><br>
<br>
<br>
<br>
</div></div></blockquote></div><br></div>