[Bug rtl-optimization/53176] [4.8 Regression] gcc.dg/lower-subreg-1.c FAILs

2012-07-13 Thread hp at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53176

Hans-Peter Nilsson  changed:

   What|Removed |Added

 Status|ASSIGNED|RESOLVED
URL|http://gcc.gnu.org/ml/gcc-p |http://gcc.gnu.org/ml/gcc-p
   |atches/2012-05/msg00609.htm |atches/2012-07/msg00280.htm
   |l   |l
 Resolution||FIXED

--- Comment #26 from Hans-Peter Nilsson  2012-07-13 
08:04:39 UTC ---
fixed in default costs too now.


[Bug rtl-optimization/53176] [4.8 Regression] gcc.dg/lower-subreg-1.c FAILs

2012-07-12 Thread hp at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53176

--- Comment #25 from Hans-Peter Nilsson  2012-07-12 
21:14:19 UTC ---
Author: hp
Date: Thu Jul 12 21:14:14 2012
New Revision: 189441

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=189441
Log:
PR rtl-optimization/53176
* rtlanal.c (rtx_cost): Adjust default cost for X with a
UNITS_PER_WORD factor for all X according to the size of
its mode, not just for SUBREGs with untieable modes.
Handle SET.  Use factor * factor for MULT, DIV, UDIV,
MOD, UMOD.

Modified:
trunk/gcc/ChangeLog
trunk/gcc/rtlanal.c


[Bug rtl-optimization/53176] [4.8 Regression] gcc.dg/lower-subreg-1.c FAILs

2012-05-08 Thread hp at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53176

Hans-Peter Nilsson  changed:

   What|Removed |Added

 Status|NEW |ASSIGNED
URL||http://gcc.gnu.org/ml/gcc-p
   ||atches/2012-05/msg00609.htm
   ||l
 AssignedTo|unassigned at gcc dot   |hp at gcc dot gnu.org
   |gnu.org |

--- Comment #24 from Hans-Peter Nilsson  2012-05-09 
06:22:41 UTC ---
Generic patch posted.  I'll assign myself until the patch is shot down, though
I haven't even tested whether it fixes the original target reported.


[Bug rtl-optimization/53176] [4.8 Regression] gcc.dg/lower-subreg-1.c FAILs

2012-05-08 Thread ubizjak at gmail dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53176

--- Comment #23 from Uros Bizjak  2012-05-08 16:10:07 
UTC ---
Author: uros
Date: Tue May  8 16:01:54 2012
New Revision: 187289

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=187289
Log:
PR target/53176
* config/i386/i386.c (ix86_set_reg_reg_cost): New function.
(ix86_rtx_costs): Handle SET.


Modified:
trunk/gcc/ChangeLog
trunk/gcc/config/i386/i386.c


[Bug rtl-optimization/53176] [4.8 Regression] gcc.dg/lower-subreg-1.c FAILs

2012-05-06 Thread hp at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53176

--- Comment #22 from Hans-Peter Nilsson  2012-05-06 
23:28:55 UTC ---
(In reply to comment #21)

Hopefully it was obvious, but:

> ... where natural_set_cost is the cost of
> setting a register (possibly the default)

... for the UNITS_PER_WORD case ...


[Bug rtl-optimization/53176] [4.8 Regression] gcc.dg/lower-subreg-1.c FAILs

2012-05-06 Thread hp at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53176

--- Comment #21 from Hans-Peter Nilsson  2012-05-06 
23:25:40 UTC ---
All this should be taken care of by the default rtx costs; I don't think any
target patches should be needed for these targets at least not for this case. 
The default should be N*natural_set_cost, where natural_set_cost is the cost of
setting a register (possibly the default) and N is the number of UNITS_PER_WORD
for the rtx.
And, the target rtx cost hook should only need to handle rtxes that are valid
for the target; no phony insns in larger modes for which there is no named
pattern (not documented as such but inferring from only valid addresses needing
to be handled by TARGET_ADDRESS_COST).


[Bug rtl-optimization/53176] [4.8 Regression] gcc.dg/lower-subreg-1.c FAILs

2012-05-06 Thread olegendo at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53176

--- Comment #20 from Oleg Endo  2012-05-06 
19:21:18 UTC ---
(In reply to comment #19)
> "olegendo at gcc dot gnu.org"  writes:
> > --- Comment #18 from Oleg Endo  2012-05-06 
> > 18:09:37 UTC ---
> > On SH an issue popped up because lower-subreg would not split multi-word 
> > regs
> > anymore.  Could somebody please have a look at comment #2 and the proposed
> > patch in PR 53250?
> 
> Unfortunately I messed up the choice of cost routines in the original patch.
> I just committed the fix for that.  The SH rtx_costs routine should now see
> (set (reg) (reg)) and (set (reg) (const_int 0)) rtxes, so you should
> be able to set the costs there.  See:
> 
> http://gcc.gnu.org/ml/gcc-patches/2012-05/msg00425.html
> 
> for a similar MIPS patch.

Yep, I just saw it on the patches list.  I'm on it.  Thanks.


[Bug rtl-optimization/53176] [4.8 Regression] gcc.dg/lower-subreg-1.c FAILs

2012-05-06 Thread rdsandiford at googlemail dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53176

--- Comment #19 from rdsandiford at googlemail dot com  2012-05-06 19:17:03 UTC ---
"olegendo at gcc dot gnu.org"  writes:
> --- Comment #18 from Oleg Endo  2012-05-06 
> 18:09:37 UTC ---
> On SH an issue popped up because lower-subreg would not split multi-word regs
> anymore.  Could somebody please have a look at comment #2 and the proposed
> patch in PR 53250?

Unfortunately I messed up the choice of cost routines in the original patch.
I just committed the fix for that.  The SH rtx_costs routine should now see
(set (reg) (reg)) and (set (reg) (const_int 0)) rtxes, so you should
be able to set the costs there.  See:

http://gcc.gnu.org/ml/gcc-patches/2012-05/msg00425.html

for a similar MIPS patch.


[Bug rtl-optimization/53176] [4.8 Regression] gcc.dg/lower-subreg-1.c FAILs

2012-05-06 Thread olegendo at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53176

Oleg Endo  changed:

   What|Removed |Added

 CC||olegendo at gcc dot gnu.org

--- Comment #18 from Oleg Endo  2012-05-06 
18:09:37 UTC ---
On SH an issue popped up because lower-subreg would not split multi-word regs
anymore.  Could somebody please have a look at comment #2 and the proposed
patch in PR 53250?


[Bug rtl-optimization/53176] [4.8 Regression] gcc.dg/lower-subreg-1.c FAILs

2012-05-04 Thread ubizjak at gmail dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53176

--- Comment #17 from Uros Bizjak  2012-05-04 08:20:27 
UTC ---
(In reply to comment #16)
> The x86 failure:
> 
> FAIL: gcc.target/i386/movbe-2.c scan-assembler-times movbe[ \t] 4
> 
> is a register allocator/reload problem. I will open new PR for this.

-> PR 53227


[Bug rtl-optimization/53176] [4.8 Regression] gcc.dg/lower-subreg-1.c FAILs

2012-05-03 Thread ubizjak at gmail dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53176

Uros Bizjak  changed:

   What|Removed |Added

Summary|[4.8 Regression]|[4.8 Regression]
   |gcc.target/i386/movbe-2.c   |gcc.dg/lower-subreg-1.c
   |and gcc.dg/lower-subreg-1.c |FAILs

--- Comment #16 from Uros Bizjak  2012-05-04 06:54:38 
UTC ---
The x86 failure:

FAIL: gcc.target/i386/movbe-2.c scan-assembler-times movbe[ \t] 4

is a register allocator/reload problem. I will open new PR for this.