This is the mail archive of the gcc-patches@gcc.gnu.org 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]

Re: Dead store elimination patch for switch statements


> Date: Wed, 27 Oct 1999 20:45:31 +0100
> From: Joern Rennecke <amylaar@cygnus.co.uk>
> Cc: gcc-patches@gcc.gnu.org, rth@cygnus.com.amylaar@cygnus.co.uk
> Newsgroups: cygnus.egcs.patches
> X-Newsreader: TIN [version 1.2 PL2]
> 
> In article <199910270422.OAA01206@gluttony.geoffk.wattle.id.au> you wrote:
> 
> : The real fix is to treat switch tables in the same way as other
> : constants, for instance CONST_DOUBLE, and have them explicitly inside
> : the jump instruction and emitted to the constant pool in the usual
> : way.
> 
> Some architectures don't allow the ADDR_(DIFF_)VEC to be placed arbitrarily.

I'm not sure what you mean by 'arbitrarily', but almost all
architectures require some special placement for eg. CONST values, as
in

(add (reg r3) (const 7))

you can't just throw the 'const 7' in .rodata :-).

On MIPS, a similar thing is true of 'const_double', they get output
into section .lit8 which is special.

-- 
Geoffrey Keating <geoffk@cygnus.com>


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