diff --git a/gcc/rtlanal.c b/gcc/rtlanal.c index 321363f..d9f57c3 100644 --- a/gcc/rtlanal.c +++ b/gcc/rtlanal.c @@ -4164,6 +4164,13 @@ rtx_cost (rtx x, machine_mode mode, enum rtx_code outer_code, return COSTS_N_INSNS (2 + factor); break; + case TRUNCATE: + if (MODES_TIEABLE_P (mode, GET_MODE (XEXP (x, 0)))) + { + total = 0; + break; + } + /* FALLTHRU */ default: if (targetm.rtx_costs (x, mode, outer_code, opno, &total, speed)) return total;