Re: Late combine & mode switch

2024-09-12 Thread Richard Sandiford via Gcc
Sorry for the slow response. Xi Ruoyao writes: > Hi Richard, > > When I hack the LoongArch backend I notice something like > > slli.d $r4, $r4, 2 > add.w $r4, $r4, $r5 > > Or > > (set (reg:DI 4) (ashift:DI (reg:DI 4) (const_int 2)) > (set (reg:DI 4) > (sign_extend:DI (add:SI (reg:SI 4) (reg:

Late combine & mode switch

2024-09-10 Thread Xi Ruoyao via Gcc
Hi Richard, When I hack the LoongArch backend I notice something like slli.d $r4, $r4, 2 add.w $r4, $r4, $r5 Or (set (reg:DI 4) (ashift:DI (reg:DI 4) (const_int 2)) (set (reg:DI 4) (sign_extend:DI (add:SI (reg:SI 4) (reg:SI 5 can appear after split. On LoongArch it can be done via an