<div dir="ltr"><div class="gmail_extra"><br><div class="gmail_quote">On Fri, Jun 13, 2014 at 11:00 AM, Tim Northover <span dir="ltr"><<a href="mailto:t.p.northover@gmail.com" target="_blank">t.p.northover@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div id=":20v" class="a3s" style="overflow:hidden">Hi Chandler,<br>
<div class=""><br>
> So, I see where you're going here, but I'm curious -- why not just switch<br>
> ATOMIC_CMP_SWAP to have a second i1 value, and still be strong? Is this<br>
> *just* to support expanding? I wonder if that's really useful rather than<br>
> just lowering it directly on the various targets....<br>
<br>
</div>I tried that originally, but quickly got into murky waters with all<br>
the targets I've got basically no clue about.<br>
<br>
It still could have been the best option (I started poking at Mips),<br>
but for one particularly nasty facet: you can select ATOMIC_CMP_SWAP<br>
in TableGen, but not ATOMIC_CMP_SWAP_WITH_SUCCESS (multiple results<br>
and all that).<br>
<br>
That means even getting selection back to the status quo would have<br>
been a lot of duplicated C++ code in multiple targets, all for what's<br>
basically a dead-end in most cases. It's far easier to make use of the<br>
i1 before the DAG level if possible.<br>
<br>
Anyway, that was my reasoning. Possibly more pragmatism than principle.</div></blockquote></div><br>No, it makes a certain amount of sense.</div><div class="gmail_extra"><br></div><div class="gmail_extra">I'd personally much rather we had *just* the multiple result variant in the DAG, but I can see it being really annoying to get there directly. Perhaps eventually targets will have adapted far enough that we can kill off the expanded form, or invert them.</div>
<div class="gmail_extra"><br></div><div class="gmail_extra">Certainly, I agree with only exposing the strong variant once you hit the DAG.</div><div class="gmail_extra"><br></div><div class="gmail_extra">So, I say carry on unless others on the list see serious problems here.</div>
<div class="gmail_extra">-Chandler</div></div>