<html><head><meta http-equiv="Content-Type" content="text/html charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class=""><br class=""><div><blockquote type="cite" class=""><div class="">On Jul 22, 2016, at 8:18 AM, David Blaikie <<a href="mailto:dblaikie@gmail.com" class="">dblaikie@gmail.com</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><div dir="ltr" class="">I've forgotten most of this review (but I've reread the thread to get as much context as I can) - but is there a reason you have op-(APInt, uint64), but not op-(uint64, APInt) (or am I misreading the patch and that's already somewhere?) (same question for op+). Seems like that'll catch someone by surprise when APInt-uint64 performs better than uint64+APInt?<br class=""></div></div></blockquote>You’re right, there was no good reason to leave those out.  I think my reasoning was that I wanted to make use of the add_1 and sub_1 helpers which isn’t easy in the latter case.  As it is, I’ve added them, the sub case won’t necessarily be fast as it has to loop over all the value to negate it, but it should still save the allocation which was the main reason for this whole series of patches.</div><div><br class=""></div><div>Also, it was just odd that ‘APInt + 1’ compiled but ‘1 + APInt’ gave an error.  Even if the implementation was no faster, it was still worth adding these just for consistency.  Nice catch!</div><div><br class=""></div><div>So same patch as before and also added those methods and tests for them.</div><div><br class=""></div><div>Thanks,</div><div>Pete</div><div><br class=""></div><div></div></body></html>