<div dir="ltr"><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Sep 3, 2014 at 9:56 AM, Hans Wennborg <span dir="ltr"><<a href="mailto:hans@chromium.org" target="_blank">hans@chromium.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 Wed, Sep 3, 2014 at 9:47 AM, Chandler Carruth <<a href="mailto:chandlerc@google.com">chandlerc@google.com</a>> wrote:<br>
> As long as 'alignAddr' can move a pointer more than one past the end of the<br>
> allocation, it doesn't really work IMO. But this is all such a technicality,<br>
> I'm not sure how much continued hacking is worth here.<br>
<br>
</span>I'm not sure I'm following here. alignAddr doesn't work with a<br>
pointer, it's just rounding up a uintptr_t. Are you concerned about<br>
comparing that uintptr_t to another uintptr_t?</blockquote></div><br>Ok, so it may be wrapping but isn't hitting UB. And the difference is defined and correct even if wrapped.... OK, sure.</div></div>