This is the mail archive of the
libc-alpha@sourceware.cygnus.com
mailing list for the glibc project.
Re: I think I found a bug...
- To: ralf at uni-koblenz dot de
- Subject: Re: I think I found a bug...
- From: Geoff Keating <geoffk at cygnus dot com>
- Date: Wed, 1 Mar 2000 08:51:50 -0800
- CC: myg at tempest dot din dot net, libc-alpha at sourceware dot cygnus dot com, bugs at gnu dot org
- References: <Pine.LNX.4.10.10002290219070.29139-100000@tempest.din.net> <20000301133107.A1864@uni-koblenz.de>
> Date: Wed, 1 Mar 2000 13:31:07 +0100
> From: Ralf Baechle <ralf@uni-koblenz.de>
> Cc: libc-alpha@sourceware.cygnus.com, bugs@gnu.org
> > It seems that the problem really stems from glibc's inline string
> > intrinsics. While the GCC compiler should not use vast amounts of virtual
> > memory to compile such an itty-bitty routine, the GCC people suspect that
> > something in glibc is tickling some nasty behavior in GCC.
Yes. The problem is that the preprocessor macro uses the source of
the strcpy() (the second argument) about 24 times. The quoted test
case uses five nested strcpy calls, producing about eight million
copies of the strcpy macro.
Naturally, it takes substantial memory and CPU time to deal with this.
Any suggestions about what to do about it?
--
- Geoffrey Keating <geoffk@cygnus.com>