<div dir="ltr">Hi all,<div><br></div><div>The AllowFPOpFusion option passed to a target can currently take 3 different values, Fast, Standard or Strict (TargetOptions.h), being Standard the default.</div><div><br></div><div>
In the DAGCombiner, during the combination of mul and add/subtract into multiply-and-add/subtract, this option is expected to be Fast in order to enable the combine. This means, that by default no multiply-and-add opcodes are going to be generated. If I understand it correctly, this is undesirable given that multiply-and-add for targets like PPC (I am not sure about all the other targets) does not pose any rounding problem and it can even be more accurate than performing the two operations separately.</div>
<div><br></div><div>Also, in TargetOptions.h I read:</div><div><br></div><div>Standard, // Only allow fusion of 'blessed' ops (currently just fmuladd)<br></div><div><br></div><div>which made me suspect that the check against Fast in the DAGCombiner is not correct. </div>
<div><br></div><div><div>I was wondering if this is something to be fixed in the DAG combiner or if the target should set a different option to be checked by the DAGCombiner saying that mul-add/subtract is okay. </div></div>
<div><br></div><div>Any comments?</div><div><br></div><div>Thanks in advance!</div><div>Samuel</div></div>