bug: egcs 1.1.2 with -fprefix-function-name

Andrew Morton morton@nortelnetworks.com
Sat Sep 25 03:43:00 GMT 1999


Greetings.

I believe we have a bug in egcs. I'm running Linux-Mandrake 6.0

bix:~> uname -a
Linux bix 2.2.9-27mdk #1 Mon Jun 14 16:44:05 CEST 1999 i586 unknown

bix:~> g++ -v
Reading specs from /usr/lib/gcc-lib/i686-pc-linux-gnu/pgcc-2.91.66/specs
gcc version pgcc-2.91.66 19990314 (egcs-1.1.2 release)


Here is 'bad.i':

$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$
struct cp_eh_info
{
  void *value;
};

extern "C" cp_eh_info **__get_eh_info () __asm__ ("__get_eh_info");

extern bool __is_pointer (void *);

extern "C" void *
__cp_exception_info (void)
{
  return &((*__get_eh_info ())->value);
}
$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$

I compile it with:

/usr/lib/gcc-lib/i686-pc-linux-gnu/pgcc-2.91.66/cc1plus bad.i \
	-quiet -dumpbase stubs-gxx2.cc -g -g -fcheck-memory-usage \
	-fprefix-function-name -fexceptions -o bad.s

And then run

bix:~> grep '*__' bad.s
        call chkr.*__get_eh_info


That asterisk should not be in there!


Good luck and thanks for a wonderful compiler,

Andrew.


More information about the Gcc-bugs mailing list