OOPs, I don't know that. Anyway, I won't count on GCC to reliably pick up these complex patterns. In our port, we implemented clz/ffs/etc as intrinsics though they are present as standard patterns.
Bingfeng > -----Original Message----- > From: fanqifei [mailto:fanqi...@gmail.com] > Sent: 13 January 2010 10:26 > To: Bingfeng Mei > Cc: gcc@gcc.gnu.org > Subject: Re: GCC-How does the coding style affect the insv > pattern recognization? > > 2010/1/13 Bingfeng Mei <b...@broadcom.com>: > > Your instruction is likely too specific to be picked up by GCC. > > You may use an intrinisc for it. > > > > Bingfeng > > but insv is a standard pattern name. > the semantics of expression x= (x&0xFF00FFFF) | ((i<<16)&0x00FF0000); > is exactly what insv can do. > I all tried mips gcc cross compiler, and ins is also not generated. > Intrinsic is a way to resolve this though. Maybe there is no > other better way. > > BTW, > There is a special case(the bit position is 0): > 235: f0 97 fc mvi a9 -0x4; #move immediate to reg > 238: ff e9 94 and a9 a14 a9; > 23b: f0 95 02 or a9 0x2; > The above three instructions can be replaced by mvi and insv. But the > fact is not in the combine pass. > > Qifei Fan > >