Commit 86b001e0 by Bin Cheng Committed by Bin Cheng

* rtlanal.c (rtx_cost): Handle TRUNCATE between tieable modes.

From-SVN: r247881
parent e81c8328
2017-05-11 Bin Cheng <bin.cheng@arm.com>
* rtlanal.c (rtx_cost): Handle TRUNCATE between tieable modes.
2017-05-11 Richard Biener <rguenther@suse.de> 2017-05-11 Richard Biener <rguenther@suse.de>
* passes.c (execute_function_todo): Verify loops if they are * passes.c (execute_function_todo): Verify loops if they are
......
...@@ -4164,6 +4164,13 @@ rtx_cost (rtx x, machine_mode mode, enum rtx_code outer_code, ...@@ -4164,6 +4164,13 @@ rtx_cost (rtx x, machine_mode mode, enum rtx_code outer_code,
return COSTS_N_INSNS (2 + factor); return COSTS_N_INSNS (2 + factor);
break; break;
case TRUNCATE:
if (MODES_TIEABLE_P (mode, GET_MODE (XEXP (x, 0))))
{
total = 0;
break;
}
/* FALLTHRU */
default: default:
if (targetm.rtx_costs (x, mode, outer_code, opno, &total, speed)) if (targetm.rtx_costs (x, mode, outer_code, opno, &total, speed))
return total; return total;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment