<div dir="ltr">On 25 January 2013 17:48, 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:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
I think that we need to improve ::isTruncateFree, ::isZextFree, etc to include all of the free conversions. Vector and Scalar.<br></blockquote><div><br></div><div>Hi Nadav,<br></div><div><br></div><div style>Yes, and the question is: TargetLowering's isZExtFree or TargetTransform's isZExtFree?</div>
<div style><br></div><div style>TargetTransform (TT) only has the free checks on types, while TargetLowering (TL) has on SDValue and destination type.</div><div style><br></div><div style>For my purposes, I need the operation information, so I was going to implement on TL, but I can't see where the TT queries that, though BasicTTI queries isTruncateFree(Type, Type), which is not the one I want to override.</div>
<div style><br></div><div style>Do you see the confusion?</div><div style><br></div><div style>Some truncates are not free (16-bit results have to move to D* first), so I could just assume this is the case by type, but I wanted to limit to the arithmetic operations, not loads and stores, that have their own halving and doubling that are, sometimes, free.</div>
<div style><br></div><div style>But since TT already lost the information on the operations (passing only the type), I can't reach that info. And since ARMTTI is supposed to only apply the exceptions, I didn't want to override it on that.</div>
<div style><br></div><div style>Am I making any sense?</div><div style><br></div><div style>cheers,</div><div style>--renato</div></div></div></div>