<div dir="ltr">On 28 February 2013 19:09, Benjamin Kramer <span dir="ltr"><<a href="mailto:benny.kra@googlemail.com" target="_blank">benny.kra@googlemail.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">We make the cost for calling libm functions extremely high as emitting the<br>
calls is expensive and causes spills (on x86) so performance suffers. We still<br>
vectorize important calls like ceilf and friends on SSE4.1. and fabs.<br>
<br>
Differential Revision: <a href="http://llvm-reviews.chandlerc.com/D466" target="_blank">http://llvm-reviews.chandlerc.com/D466</a><br>
<br>
Added:<br>
    llvm/trunk/test/Analysis/CostModel/X86/intrinsic-cost.ll<br>
Modified:<br>
    llvm/trunk/lib/Analysis/CostModel.cpp<br>
    llvm/trunk/lib/CodeGen/BasicTargetTransformInfo.cpp<br></blockquote><div><br></div><div style>Hi Ben,</div><div style><br></div><div style>I still think the intrinsic detection should be in the X86 TTI and not here. You can leave the basic cost (isLegal etc) here, but the detection of intrinsics, since it's X86 specific, should be in there.</div>
<div style><br></div><div style>If other platforms have the same list, they should also override this method.</div><div style><br></div><div style>cheers,</div><div style>--renato</div></div></div></div>