Re: Question about "instruction merge" pass when optimizing for size

2015-08-20 Thread Jeff Law
On 08/20/2015 01:07 AM, sa...@hederstierna.com wrote: From: Jeff Law More important is to determine *why* we're getting these patterns. In the IRA/LRA world, they should be a lot less common. Yes I agree this phenomena seems more common after introdu

Re: Question about "instruction merge" pass when optimizing for size

2015-08-20 Thread sa...@hederstierna.com
> > From: Jeff Law > More important is to determine *why* we're getting these patterns. In > the IRA/LRA world, they should be a lot less common. Yes I agree this phenomena seems more common after introducing LRA. Though I was thinking that such a pass

RE: Question about "instruction merge" pass when optimizing for size

2015-08-19 Thread Robert Suchanek
(It appears I accidentally dropped the mailing list) Hi, > On 08/19/2015 02:38 PM, DJ Delorie wrote: > > I've seen this on other targets too, sometimes so bad I write a quick > > target-specific "stupid move optimizer" pass to clean it up. > > > > A generic pass would be much harder, but very use

Re: Question about "instruction merge" pass when optimizing for size

2015-08-19 Thread Jeff Law
On 08/19/2015 02:38 PM, DJ Delorie wrote: I've seen this on other targets too, sometimes so bad I write a quick target-specific "stupid move optimizer" pass to clean it up. A generic pass would be much harder, but very useful. More important is to determine *why* we're getting these patterns. I

RE: Question about "instruction merge" pass when optimizing for size

2015-08-19 Thread Matthew Fortune
DJ Delorie writes: > I've seen this on other targets too, sometimes so bad I write a quick > target-specific "stupid move optimizer" pass to clean it up. > > A generic pass would be much harder, but very useful. Robert (on cc) is currently attempting some improvements to the regrename pass to tr

Re: Question about "instruction merge" pass when optimizing for size

2015-08-19 Thread DJ Delorie
I've seen this on other targets too, sometimes so bad I write a quick target-specific "stupid move optimizer" pass to clean it up. A generic pass would be much harder, but very useful.

Question about "instruction merge" pass when optimizing for size

2015-08-19 Thread sa...@hederstierna.com
for performance its equal due to other instruction stall etc, but when optimizing for size, its quite straight forward that you can gain bytes on these transformations, if possible, and should be preferred. The thing I was thinking of if it was possible to add a more generic GCC pass that could

Re: Optimizing for size

2008-07-14 Thread Alexandre Pereira Nunes
This could be related to PR31849. If so, this is well-known before the 4.3.0 release, and altought IIRC it affects other architetures as well (powerpc and m68k at least), apparently no one proposed a solution yet. Please see: http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31849 Thanks, Alexandre