Hi, Thanks for your reply :)
Maybe there are some register limits in reload pass with my case like <multiply-add> We need to expand to ‘mov’ and ‘madd’ first to get suitable registers. —Jojo 在 2020年7月3日 +0800 AM5:35,Jim Wilson <j...@sifive.com>,写道: > On Wed, Jul 1, 2020 at 8:40 PM <jiejie_r...@c-sky.com> wrote: > > GCC seems to overlap register bewteen DEST and SOURCE in different machine > > mode, > > Is there any target hooks to control this feature ? > > I use <Constraint Modifier> ‘&’ to forbid register allocator to overlap > > bewteen DEST and SOURCE, > > but there are some redundancy instructions in the result code :( > > & is the correct solution in general. > > Presumably this is about your draft v0.7.1 vector port. This port > uses an unspec in every pattern. This limits the compiler's ability > to optimize code. You might get better results if you eliminated as > many of the unspecs as you can. > > You might want to check TARGET_MODES_TIEABLE_P though this is mostly > about casts and moves not register allocation. > > Jim