This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: optimization/902: x86 optimization bug with sibling call and -fomit-frame-pointer
- To: Richard Henderson <rth at redhat dot com>
- Subject: Re: optimization/902: x86 optimization bug with sibling call and -fomit-frame-pointer
- From: "Zack Weinberg" <zackw at stanford dot edu>
- Date: Tue, 28 Nov 2000 16:48:25 -0800
- Cc: Fergus Henderson <fjh at cs dot mu dot oz dot au>, gcc-gnats at gcc dot gnu dot org, gcc-patches at gcc dot gnu dot org
- References: <200011271106.WAA25200@hg.cs.mu.oz.au> <20001128161923.A29422@redhat.com>
On Tue, Nov 28, 2000 at 04:19:23PM -0800, Richard Henderson wrote:
> On Mon, Nov 27, 2000 at 10:06:43PM +1100, Fergus Henderson wrote:
> > static void empty(void)
> > {
> > }
> >
> > static void foo (int a, int * b, int c, int * d)
> > {
> > malloc(20);
> > empty();
> > }
>
> We recognize that empty does nothing and mark it CONST.
Would it be practical to recognize that empty does nothing, and not
call it at all? This could be as simple as marking it to-be-inlined.
zw