Dead store elimination patch for switch statements
Geoff Keating
geoffk@ozemail.com.au
Wed Oct 27 22:28:00 GMT 1999
> Date: Tue, 26 Oct 1999 21:34:44 -0700
> From: Richard Henderson <rth@cygnus.com>
> Cc: gcc-patches@gcc.gnu.org
>
> On Wed, Oct 27, 1999 at 02:22:55PM +1000, Geoff Keating wrote:
> > + for (inote = REG_NOTES (insn); inote; inote = XEXP (inote, 1))
> > + {
> > + if (REG_NOTE_KIND (inote) == REG_LABEL)
>
> Any reason not to use find_reg_note?
What if there was more than one label referenced?
I'm particularly thinking of
(set x (const (minus (code_label ".L1") (code_label ".LC0"))))
which is the sort of thing you can get when you have incomplete
constant propagation on switch statements; 'L1' is the real branch
target and 'LC0' is the address of the switch, and later 'LC0' will be
added back in.
--
Geoffrey Keating <geoffk@cygnus.com>
More information about the Gcc-patches
mailing list