On Tue, Nov 8, 2022 at 2:50 PM Jakub Jelinek wrote: > > On Tue, Nov 08, 2022 at 02:47:35PM +0100, Aldy Hernandez wrote: > > Well, perhaps we should just nuke update_nan_sign() altogether, and > > always keep the sign varying? > > > > inline bool > > propagate_nans (frange &r, const frange &op1, const frange &op2) > > { > > if (op1.known_isnan () || op2.known_isnan ()) > > { > > r.set_nan (op1.type ()); > > return true; > > } > > return false; > > } > > > > I'm fine either way. The less code the better :). > > Yes, but you had 2 callers, so something needs to be done also if > in foperator_plus::fold_range. We can also remove the update_nan_sign() in the other call because the r.set() before it sets a default NAN (with a varying sign). Attached patch in testing. Aldy