Re: [patch] regcprop fix for PR rtl-optimization/54300

2014-01-09 Thread Richard Earnshaw
On 20/11/13 13:57, Richard Earnshaw wrote: > On 19/11/13 17:48, Jeff Law wrote: >> On 11/19/13 10:32, Steven Bosscher wrote: >>> >>> Yes. In the GCC3 days it was important for sincos on i386, and on mk68 >>> it used to be important for some of the funnier patterns. Not sure if >>> it's still useful

Re: [patch] regcprop fix for PR rtl-optimization/54300

2013-11-20 Thread Richard Earnshaw
On 19/11/13 17:48, Jeff Law wrote: > On 11/19/13 10:32, Steven Bosscher wrote: >> >> Yes. In the GCC3 days it was important for sincos on i386, and on mk68 >> it used to be important for some of the funnier patterns. Not sure if >> it's still useful today, though. Might be worth looking into, just

Re: [patch] regcprop fix for PR rtl-optimization/54300

2013-11-19 Thread Jeff Law
On 11/19/13 09:43, Richard Earnshaw wrote: PR 54300 is a problem in regcprop where the compiler sees (parallel [(set (x) (y) (set (y) (x)]) (REG_UNUSED (y)) as a single-set insn (since the other operand, y, is not used) and replaces a use of x with a use of y. However, it fails to

Re: [patch] regcprop fix for PR rtl-optimization/54300

2013-11-19 Thread Jeff Law
On 11/19/13 10:32, Steven Bosscher wrote: Yes. In the GCC3 days it was important for sincos on i386, and on mk68 it used to be important for some of the funnier patterns. Not sure if it's still useful today, though. Might be worth looking into, just to avoid the confusion in the future. I doubt

Re: [patch] regcprop fix for PR rtl-optimization/54300

2013-11-19 Thread Steven Bosscher
On Tue, Nov 19, 2013 at 6:27 PM, Jeff Law wrote: > I don't remember the history here, but that may have been to better support > divmod and similar insns. Yes. In the GCC3 days it was important for sincos on i386, and on mk68 it used to be important for some of the funnier patterns. Not sure if it

Re: [patch] regcprop fix for PR rtl-optimization/54300

2013-11-19 Thread Steven Bosscher
On Tue, Nov 19, 2013 at 6:22 PM, Richard Earnshaw wrote: >>> as a single-set insn (since the other operand, y, is not used) and >>> replaces a use of x with a use of y. However, it fails to take into >>> account that y has been clobbered in the insn itself. >> >> Ah, wait. Incorrect use of single_

Re: [patch] regcprop fix for PR rtl-optimization/54300

2013-11-19 Thread Jeff Law
On 11/19/13 10:17, Steven Bosscher wrote: On Tue, Nov 19, 2013 at 5:43 PM, Richard Earnshaw wrote: PR 54300 is a problem in regcprop where the compiler sees (parallel [(set (x) (y) (set (y) (x)]) (REG_UNUSED (y)) as a single-set insn (since the other operand, y, is not used) and re

Re: [patch] regcprop fix for PR rtl-optimization/54300

2013-11-19 Thread Richard Earnshaw
On 19/11/13 17:17, Steven Bosscher wrote: > On Tue, Nov 19, 2013 at 5:43 PM, Richard Earnshaw wrote: >> PR 54300 is a problem in regcprop where the compiler sees >> (parallel [(set (x) (y) >>(set (y) (x)]) (REG_UNUSED (y)) >> >> as a single-set insn (since the other operand, y, is not

Re: [patch] regcprop fix for PR rtl-optimization/54300

2013-11-19 Thread Steven Bosscher
On Tue, Nov 19, 2013 at 5:43 PM, Richard Earnshaw wrote: > PR 54300 is a problem in regcprop where the compiler sees > (parallel [(set (x) (y) >(set (y) (x)]) (REG_UNUSED (y)) > > as a single-set insn (since the other operand, y, is not used) and > replaces a use of x with a use of y.

Re: [patch] regcprop fix for PR rtl-optimization/54300

2013-11-19 Thread Steven Bosscher
On Tue, Nov 19, 2013 at 5:43 PM, Richard Earnshaw wrote: > The test is unfortunately ARM specific -- I'm not aware of any generic > code that triggers this. Isn't this an insn constraint issue, then? I'd expect recog to reject the pattern if the right constraints are used. Ciao! Steven

[patch] regcprop fix for PR rtl-optimization/54300

2013-11-19 Thread Richard Earnshaw
PR 54300 is a problem in regcprop where the compiler sees (parallel [(set (x) (y) (set (y) (x)]) (REG_UNUSED (y)) as a single-set insn (since the other operand, y, is not used) and replaces a use of x with a use of y. However, it fails to take into account that y has been clobbered in