Steven Bosscher appointed RTL optimizers reviewer
It's my pleasure to announce the appointment of Steven Bosscher as RTL optimizers reviewer. Congratulations and Happy Hacking, Steven! Gerald PS: Please update MAINTAINERS accordingly.
gcc-4.9-20130811 is now available
Snapshot gcc-4.9-20130811 is now available on ftp://gcc.gnu.org/pub/gcc/snapshots/4.9-20130811/ and on various mirrors, see http://gcc.gnu.org/mirrors.html for details. This snapshot has been generated from the GCC 4.9 SVN branch with the following options: svn://gcc.gnu.org/svn/gcc/trunk revision 201654 You'll find: gcc-4.9-20130811.tar.bz2 Complete GCC MD5=4354a630d843aec32c0e0bab5f9f6a84 SHA1=0db3e4d71486960bf4309d4badfca5db60859ae1 Diffs from 4.9-20130804 are available in the diffs/ subdirectory. When a particular snapshot is ready for public consumption the LATEST-4.9 link is updated and a message is sent to the gcc list. Please do not use a snapshot before it has been announced that way.
RE: How to specify multiple OSDIRNAME suffixes for multilib (Multilib usage with MPX)?
> -Original Message- > From: gcc-ow...@gcc.gnu.org [mailto:gcc-ow...@gcc.gnu.org] On Behalf Of > Ilya Enkovich > Sent: Friday, August 09, 2013 8:37 PM > To: GCC Development > Subject: How to specify multiple OSDIRNAME suffixes for multilib (Multilib > usage with MPX)? > > Hi, > > I'm currently trying to create multilib libraries compiled with MPX. > The main difference with existing multilib variants on i386 target is > that new targets (32/mpx, 64/mpx) are compatible with old variants > (32, 64). Also we should not prevent user from using mpx if he does > not have MPX variants for some libraries - legacy versions should be > used instead. Thus we need to check several suffixes instead of one. > E.g. for 64bit MPX binary we should firstly check ../lib64/mpx, then > check ../lib64 and finally the default one. > > I looked at MULTILIB_REUSE and thought it might solve my problem > according to documentation: "And for some targets it is better to > reuse an existing multilib than to fall back to default multilib when > there is no corresponding multilib." [1]. So I tried following > declarations: > > MULTILIB_OSDIRNAMES+= m64/fmpx=../lib64/mpx > MULTILIB_REUSE = m64=m64/fmpx > > But it appeared that only the first entry for some options set counts > when multilibs are parsed in gcc.c and my reuse here is just ignored. > > Is it a wrong implementation of MULTILIB_REUSE or my wrong > understanding of this option? Is there a way to implement mpx > multilibs still allowing legacy ones when some mpx libs are missing? > > [1] http://gcc.gnu.org/onlinedocs/gccint/Target-Fragment.html#Target- > Fragment > > Thanks, > Ilya Hi Ilya, Sorry for the later response. I am the author of MULTILIB_REUSE. So far this feature is not flexible enough to meet your requirement. It can't dynamically decide to choose m64/fmpx if such libraries are there, then secondly choose m64 if m64/fmpx don't exist. This feature only makes a static decision. The following statement: MULTILIB_REUSE = m64=m64/fmpx means that when options m64 and fmpx are given, we should reuse libraries for m64 always. And for this purpose, we also need: MULTILIB_EXCEPTIONS = m64/fmpx to make sure libraries for "m64 fmpx" won't be built. If m64/fmpx isn't excluded, the MULTILIB_REUSE will think the required libraries are there and no need to reuse. IMHO, the way used by gcc to select multilib is based on string match rather than detecting the existence of libraries. So the flexible way like you wanted isn't supported yet. BR, Terry
Re: load reverse
Anyone please help me to get out of this issue Thanks, Sravan On Thu, Aug 8, 2013 at 5:29 PM, sravan megan wrote: > Hi All, > >I am new to GCC. I was working in an Embedded processor with > GCC-4.6.4 version. > >I need to add load/store reverse instructions to the MD file. > >My instructions will look as below: > >LWX Rd,Ra,Rb > > operation: Addr := Ra + Rb > Rd := *Addr(loading data with the opposite endianness) > > SWX Rd,Ra,Rb > > operation: Addr := Ra + Rb > *Addr := Rd(storing data with the opposite endianness) > > > > To add the above instructions in to md file I tried below pattern in md > file > > (define_insn "movsi_rev" > [(set (match_operand:SI 0 "nonimmediate_operand" "=d,m") > (bswap: SI (match_operand:SI 1 "move_src_operand" "m,d")))] > "" > "@ >lwx\t%0,%1,%0 >swx\t%0,%1,%0" > [(set_attr "type" "load,store") > (set_attr "mode" "SI") > (set_attr "length""4,4")]) > > >I wrote a small testcase which is generating swx instruction but > the operands are more due to which it is failing in assembler phase > > ex: > int store_rev(int *n) > { > return *n) & 0xff00) >> 24) > | (((*n) & 0x00ff) >> 8) > | (((*n) & 0xff00) << 8) > | (((*n) & 0x00ff) << 24)); > > } > > for the above store_rev function I need to generate only single swx > instruction. > I was successful in generating the swx instruction but instead of 3 > registers compiler is generating one extra operand "0" swx r0,r2,0,r0 > >ex: instead of swx r0,r2,r0 it is generating swx r0,r2,0,r0 > > can anyone please help me in removing the extra operand in the above > instruction. > > Thanks, > Sravan