<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On 17 December 2013 19:10, Philip Reames <span dir="ltr"><<a href="mailto:listmail@philipreames.com" target="_blank">listmail@philipreames.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
  
    
  
  <div bgcolor="#FFFFFF" text="#000000"><div class="im">
    <div><span style="color:rgb(34,34,34)">Specifically with regards to metadata, why is the metadata on the
    call site not the function declaration?  I would expect that a call
    to "cos" would always vectorize to the same "cos4".  Is supporting
    different vectorizations at different points of the program a key
    goal?</span></div></div></div></blockquote><div><br></div><div>Yes. Sometimes...</div><div><br></div><div>See the test in the patch for an idea of two different functions, maybe both available, maybe not.</div><div><br>
</div><div>Also, some variants could be more efficient in some cases, while some in others. This may sound vague, but OpenCL has such a large number of functions that I'd be surprised if there were only simple cases... James can give more concrete examples on where this is important.<br>
</div><div><br></div><div>In a strictly libc case, you may create several variants of memcpy based on the arguments (restrict or volatile, address space boundaries, etc), and apply the fastest you can on each case.</div><div>
<br></div><div>cheers,</div><div>--renato</div></div></div></div>