This is the mail archive of the mailing list for the GCC project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] libgcc/MIPS: Fill in delay slots of (some) MIPS16 call stubs

On Mon, 29 Jul 2013, Maciej W. Rozycki wrote:

> > >  These stubs are I believe not really covered in our testing, because they 
> > > require a mixed standard-MIPS/MIPS16 environment.
> > 
> > What's the barrier to testing a mixed environment?  The normal *-linux-gnu
> > configurations have no MIPS16 multilibs, so you should be able to test it
> > on a plain mips-linux-gnu configuration using --target_flags unix/-mips16.
> > FWIW I've been using the mips64-linux-gnu equivalent
> > (--target_flags unix/-mabi=32/-mips16) without problems.  
> > 
> > Or if you don't want to test on GNU/Linux, you should be able to use something
> > like mips64-elf configured with whichever --with-arch= you like (and an
> > appropriate simulator).  Long time since I tried that though.  I prefer
> > testing on GNU/Linux because it also covers symbol visibility
> > and has better libgfortran support.
>  We don't have specific coverage, but something in the testsuite might 
> happen to pull one or more of these thunks indeed.

 It is as I feared, the coverage is sparse.  The only call/return stubs 
pulled across the testsuite are:


(there are some call stubs too and some PIC stubs, but they all use 
different code).  Of these only the first suffers from the old GAS 

00000000 <__mips16_call_stub_sf_5>:
   0:	03e09021 	move	s2,ra
   4:	44846000 	mtc1	a0,$f12
   8:	44857000 	mtc1	a1,$f14
   c:	0040f809 	jalr	v0
  10:	0040c821 	move	t9,v0
  14:	44020000 	mfc1	v0,$f0
  18:	02400008 	jr	s2
  1c:	00000000 	nop

as only stubs that return a single float result are affected (ones that 
return a single complex or a double result are not, because they use more 
than one CP1 move in their epilogues and old GAS is capable enough to 
schedule the last move into the JR's delay slot itself).

> > > 	libgcc/
> > > 	* config/mips/mips16.S (DELAYf): Alias to DELAYt for the MIPS IV 
> > > 	ISA and up.
> > 
> > OK, thanks, but please do run it through the testsuite first.
>  I'll see if I can do it -- the MIPS/Linux tree I used for recent MIPS32r2 
> MADD.fmt testing has no MIPS16 multilibs configured, so it might happen to 
> just work with -mips16 passed as an extra option (otherwise MIPS16 libs 
> would be automagically picked instead).  I'll check if binaries executeed 
> really pulled any of the thunks concerned.

 No regressions seen, applied now.  Thanks for your review.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]