public inbox for gcc@gcc.gnu.org
 help / color / mirror / Atom feed
* Deletion of trivial insn during IRA
@ 2011-10-03 11:17 Paulo J. Matos
  2011-10-03 20:24 ` Ian Lance Taylor
  0 siblings, 1 reply; 3+ messages in thread
From: Paulo J. Matos @ 2011-10-03 11:17 UTC (permalink / raw)
  To: gcc


Hi, 

I am trying to find where IRA, is deleting trivial insn like:
(set r1 r1)

The problem I am facing is that I have managed to convince GCC to handle
moves that clobber RCC like:
(parallel [(set reg1 reg2) (clobber rcc)])

However, I am getting loads of insn like:
(parallel [(set r1 r2) (clobber rcc)])

in the insn stream after IRA. This is also blocking some later
optimisations.

I am trying to find where GCC actually removes insns where source and
dest are the same. I understand that if there's a general clobber then
the insn shouldn't be removed, however if the clobber is on the flags
register then it should go ahead and remove it anyway.

Can someone guide me to the right place where this is happening?

Cheers,

-- 
PMatos

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Deletion of trivial insn during IRA
  2011-10-03 11:17 Deletion of trivial insn during IRA Paulo J. Matos
@ 2011-10-03 20:24 ` Ian Lance Taylor
  2011-10-04  8:01   ` Paulo J. Matos
  0 siblings, 1 reply; 3+ messages in thread
From: Ian Lance Taylor @ 2011-10-03 20:24 UTC (permalink / raw)
  To: Paulo J. Matos; +Cc: gcc

paulo@matos-sorge.com (Paulo J. Matos) writes:

> I am trying to find where IRA, is deleting trivial insn like:
> (set r1 r1)

Search for "Discard obvious no-ops" in the function reload in the file
gcc/reload1.c.

Ian

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Deletion of trivial insn during IRA
  2011-10-03 20:24 ` Ian Lance Taylor
@ 2011-10-04  8:01   ` Paulo J. Matos
  0 siblings, 0 replies; 3+ messages in thread
From: Paulo J. Matos @ 2011-10-04  8:01 UTC (permalink / raw)
  To: gcc

Ian Lance Taylor <iant@google.com> writes:

> paulo@matos-sorge.com (Paulo J. Matos) writes:
>
>> I am trying to find where IRA, is deleting trivial insn like:
>> (set r1 r1)
>
> Search for "Discard obvious no-ops" in the function reload in the file
> gcc/reload1.c.

Thanks, that's exactly it. 

-- 
PMatos

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2011-10-04  8:01 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-10-03 11:17 Deletion of trivial insn during IRA Paulo J. Matos
2011-10-03 20:24 ` Ian Lance Taylor
2011-10-04  8:01   ` Paulo J. Matos

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).