Gcc optimization bug. (fwd)

Alvin Starr alvin@iplink.net
Tue Oct 26 04:44:00 GMT 1999


I sent this a while ago. But some mail server problems got in the way and
I forgot about it.

Alvin Starr                   ||   voice: (416)585-9971
Interlink Connectivity        ||   fax:   (416)585-9974
alvin@iplink.net              ||

---------- Forwarded message ----------
Date: Thu, 23 Sep 1999 12:18:29 -0400 (EDT)
From: Alvin Starr <alvin@iplink.net>
To: gcc-bugs@gcc.gnu.org
Subject: Gcc optimization bug.


There seems to be an optimization bug in egcs 1.1.2
This showed up a month or so ago but I am just getting around to reporting
it now. I have included the minimal source that shows the problem and the
assembler output for optimized an non-optimized statements. It seems that
the optimizer is optimizing out the second memcpy.

    The GCC version 
Reading specs from /usr/lib/gcc-lib/alpha-redhat-linux/egcs-2.91.66/specs
gcc version egcs-2.91.66 19990314/Linux (egcs-1.1.2 release)

    The system type 
cpu			: Alpha
cpu model		: PCA56
cpu variation		: 0
cpu revision		: 0
cpu serial number	: Linux_is_Great!
system type		: EB164
system variation	: SX164
system revision		: 0
system serial number	: MILO-2.0.35-c5.
cycle frequency [Hz]	: 533166880 
timer frequency [Hz]	: 1024.00
page size [bytes]	: 8192
phys. address bits	: 40
max. addr. space #	: 127
BogoMIPS		: 529.53
kernel unaligned acc	: 1 (pc=fffffc000041ad8c,va=fffffc00006f26b2)
user unaligned acc	: 76463 (pc=120198aec,va=120d2960c)
platform string		: N/A
cpus detected		: 
	
    All options you passed to the compiler 
cc -s test.c  and cc -s -O test.c

    Preprocessed output of the source file that caused the compiler error 
since the problem is in the optimization I have skipped this.

Alvin Starr                   ||   voice: (416)585-9971
Interlink Connectivity        ||   fax:   (416)585-9974
alvin@iplink.net              ||


More information about the Gcc-bugs mailing list