Date: Sun, 3 Dec 1995 14:06:58 -0800 (PST) From: Julian Elischer <julian@ref.tfs.com> To: terry@lambert.org (Terry Lambert) Cc: imb@scgt.oz.au, current@FreeBSD.org Subject: Re: changes in -current..TEST please Message-ID: <199512032206.OAA00238@ref.tfs.com> In-Reply-To: <199512032054.NAA09061@phaeton.artisoft.com> from "Terry Lambert" at Dec 3, 95 01:54:41 pm
next in thread | previous in thread | raw e-mail | index | archive | help
>
> > GCC, at optimisation levels > 1, will remove data (and code) which it
> > considers to be unreferenced. _dummy_cleanup is declared 'static' yet is
> > unreferenced in the file in which it appears. Given that 'static' implies
> > 'local to this file', this is valid behaviour. However, since the variable
> > in question really is intended to be used by things external to kern_xxx.c,
> > perhaps it should not be declared 'static' and GCC will leave it alone at
> > all optimisation settings ..
>
> How is dummy_cleanup "not referenced"?
>
> phaeton: {50} grep dummy_cleanup *.c
> kern_xxx.c:dummy_cleanup() {}
> kern_xxx.c:TEXT_SET(cleanup_set, dummy_cleanup);
poul, examine what a TEXT_SET is.....
it's an asm directive from memory, as it is actually
really a hint to the linker..
of course gcc doen't know about it.. (If I recall correctly)
>
> Looks referenced to me.
>
> I think GCC is doing bogus things.
>
> Is it also removing "cleanup_set"? That would be so incredibly bogus
> as to cause all C++ and most of the FreeBSD kernel to fail miserably.
>
>
> Terry Lambert
> terry@lambert.org
> ---
> Any opinions in this posting are my own and not those of my present
> or previous employers.
>
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199512032206.OAA00238>
