<div dir="ltr">On 6 February 2013 17:03, Nadav Rotem <span dir="ltr"><<a href="mailto:nrotem@apple.com" target="_blank">nrotem@apple.com</a>></span> wrote:<br><div class="gmail_extra"><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
I can see why freakishly large vectors would produce bad code. The type <50 x float> would be widened to the next power of two, and then split over and over again until it fits into registers. So, any <50 x float> would take 16 XMM registers, that will be spilled. The situation with integer types is even worse because you can truncate or extend from one type to another.<br>
</blockquote><div><br></div><div style>In that sense, an inner loop with sequential access would be vectorized into much better code than having a <50 x float>. </div><div style><br></div><div style>Whether this is something LLVM could do with <50 x float> or should always be up to the front-end developer, I don't know. It doesn't seem particularly hard to do it in the vectorizer, but it's also probably won't be high on the TODO list for a while.</div>
<div style><br></div><div style>cheers,</div><div style>--renato</div></div></div></div>