https://gcc.gnu.org/bugzilla/show_bug.cgi?id=89573
Richard Biener <rguenth at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |jsm28 at gcc dot gnu.org --- Comment #1 from Richard Biener <rguenth at gcc dot gnu.org> --- The FE correctly builds <<< Unknown tree: excess_precision_expr (long double) __builtin_log (p) * (long double) inv_log_of_base >>> but then convert_for_assignment seems to elide via convert_to_real_1: /* Convert (outertype)((innertype0)a+(innertype1)b) into ((newtype)a+(newtype)b) where newtype is the widest mode from all of these. */ 304 case PLUS_EXPR: 305 case MINUS_EXPR: 306 case MULT_EXPR: 307 case RDIV_EXPR: 308 { 309 tree arg0 = strip_float_extensions (TREE_OPERAND (expr, 0)); 310 tree arg1 = strip_float_extensions (TREE_OPERAND (expr, 1)); where strip_float_extensions makes the comment not true (because we ignore the casts to long double). Maybe the code in convert_and_check 1627 if (TREE_CODE (expr) == EXCESS_PRECISION_EXPR) 1628 { 1629 tree orig_type = TREE_TYPE (expr); 1630 expr = TREE_OPERAND (expr, 0); 1631 expr_for_warning = convert (orig_type, expr); 1632 if (orig_type == type) 1633 return expr_for_warning; shouldn't use convert here but convert_to_real_1 with fold_p = false? But then other code may simply elide the conversions (can we really ignore the extra rounding performed by the outer truncating conversion, ever?)