This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
RE: the rtl expression does not match in define_peephole
- From: "Dave Korn" <dave dot korn at artimi dot com>
- To: "'Dong Phuong'" <dongphuong2410 at yahoo dot com>, <gcc at gnu dot org>
- Date: Tue, 30 Sep 2008 19:53:01 +0100
- Subject: RE: the rtl expression does not match in define_peephole
- References: <116387.98531.qm@web31913.mail.mud.yahoo.com>
Dong Phuong wrote on 30 September 2008 17:32:
> But when I define peepholes to reduce it, there's
> nothing change. When I look at the rtl expression, I
> see that there something beetween the instruction ADD
> and CMP :
>
> (insn 18 16 19 0x0 (set (reg/v:HI 22)
> (plus:HI (reg/v:HI 22)
> (const_int 1 [0x1]))) -1 (nil) -----> ADD
> (nil))
>
> (note 19 18 20 NOTE_INSN_LOOP_CONT) -----> st that I
> don't understand
This is documented in the manual (which you really ought to read) alongside
all the other note types:
http://gcc.gnu.org/onlinedocs/gccint/Insns.html#index-NOTE_005fINSN_005fLOOP_0
05fCONT-2615
> (code_label 20 19 22 5 "" [0 uses])
>
> (insn 22 20 23 0x0 (set (cc0)
> (compare (reg/v:HI 22)
> (const_int 4 [0x4]))) -1 (nil) ------> CMP
> (nil))
>
>
> so does that strange expressions prevent my peepholes
> from running ?
Yes.
> And in my case, what do I have to do ?
Nothing. That's not a valid match, because there's a label in-between the
two instructions; they can't possibly be combined into one single instruction
if there's a branch target in between them.
cheers,
DaveK
--
Can't think of a witty .sigline today....