patch to fix PR49990

Vladimir Makarov vmakarov@redhat.com
Tue Aug 9 02:36:00 GMT 2011


The following patch fixes PR49990.  The problem is described on

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=49936

Reg classes which can not change modes for some pseudo were excluded 
from the consideration.  As I wrote recently, they should not.  Instead 
the correct cost for changing mode (by moving through memory or other 
class register) should be taken into the account.  I believe the cost is 
already calculated rightly for this case, fortunately.

The patch was successfully bootstrapped on x86-64 and ppc64.  Actually I 
did not find a difference in generated code on variety tests on 
x86/x86-64 and arm (that is what I tried).

Committed as rev. 177575.



2011-08-08  Vladimir Makarov <vmakarov@redhat.com>

         PR rtl-optimization/49990
         * ira-costs.c (print_allocno_costs, print_pseudo_costs): Don't
         ignore classes which can not change mode.
         (find_costs_and_classes): Ditto.

-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: pr49990.patch
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20110809/b6e0d07c/attachment.ksh>


More information about the Gcc-patches mailing list