<div class="gmail_quote">On 20 June 2012 17:15, Don Clugston <span dir="ltr"><<a href="mailto:dac@nospam.com" target="_blank">dac@nospam.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
On 20/06/12 13:22, Manu wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">I find optimisers are very good at code simplification, assuming that</blockquote><div class="im"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">

you massage the code/expressions to neatly match any architectural quirks.<br>
I also appreciate that good x86 code is possibly the hardest<br>
architecture for an optimiser to get right...<br>
</blockquote>
<br></div>
Optimizers improved enormously during the 80's and 90's, but the rate of improvement seems to have slowed.<br>
<br>
With x86, out-of-order execution has made it very easy to get reasonably good code, and much harder to achieve perfection. Still, Core i7 is much easier than Core2, since Intel removed one of the most complicated bottlenecks (on core2 and earlier there is a max 3 reads per cycle, of registers you haven't written to in the previous 3 cycles).<br>

</blockquote></div><br><div>Yeah okay, I can easily imagine the complexity for an x86 codegen.</div><div>RISC architectures are so much more predictable.</div><div><br></div><div>How do you define 'perfection'? Performance as measured on what particular machine? :)</div>