[PATCH][ARM] Get mode for rtx costs calculations for SET RTX from destination reg

Kyrill Tkachov kyrylo.tkachov@arm.com
Thu Jan 9 17:42:00 GMT 2014


Hi all,

SET RTXs don't have a mode, so the code to calculate a reg-to-reg set in the arm 
rtx costs function needs to get the mode from one of the registers involved. We 
already did that when the source is a CONST_INT.

This patch fixes that oversight and also prevents us from falling through or 
recursing, since the cost calculated for (set (reg) (reg)) should be final at 
that point.

Tested arm-none-eabi on qemu.

Ok for trunk?

Thanks,
Kyrill

2014-01-09  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>

     * config/arm/arm.c (arm_new_rtx_costs): Use destination mode
     when handling a SET rtx.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: rtx_costs_set.patch
Type: text/x-patch
Size: 1212 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20140109/91c2a99b/attachment.bin>


More information about the Gcc-patches mailing list