<div dir="ltr">In my target, I have <div style> setOperationAction(ISD::FSUB, MVT::v4f32, Expand);</div><div style><br></div><div style>This produces the desired effect in LegalizeDAG, replacing the FSUB with FADD + FNEG. However, when the vector legalizer runs, it thinks the Expand legalize action means to unroll the vector. This isn't necessary and not what I wanted.</div>
<div style><br></div><div style>Is there a way to get one and not the other? I don't want the unroll aspect of the Expand action.</div><div style><br></div><div style>I changed to a Custom lowering and duplicated the FADD+FNEG action, but the dag-combine2 stage moved this back to FSUB, which then failed to pattern match in Select. That code checks for !LegalOperations || TLI.isLegalorCustom(FSUB), which of course is true for this case.</div>
<div style><br></div><div style>Suggestions?</div><div style><br></div><div style>Thanks,</div><div style>Joe</div></div>