Path: utzoo!telly!ddsw1!lll-winken!uunet!tut.cis.ohio-state.edu!MOOSE.CITA.UTORONTO.CA!trq
From: trq@MOOSE.CITA.UTORONTO.CA (Tom Quinn)
Newsgroups: gnu.gcc.bug
Subject: bug in sparc gcc 1.31
Message-ID: <8812021502.AA29471@moose.cita.utoronto.ca>
Date: 2 Dec 88 15:02:05 GMT
Sender: daemon@tut.cis.ohio-state.edu
Distribution: gnu
Organization: GNUs Not Usenet
Lines: 77
Gcc compiles the following code into assembly that will cause a data
misalignment signal. This gcc version 1.31 on a sun4/110 running
SunOS 4.0.
Tom Quinn Canadian Institute for Theoretical Astrophysics
trq@moose.cita.utoronto.ca
UUCP - decvax!utgpu!moose!trq
BITNET - quinn@utorphys.bitnet
ARPA - trq%moose.cita.toronto.edu@relay.cs.net
The compile:
gcc -S -g -v -sun4 -c Convert.c
gcc version 1.31
/usr/local/lib/gcc-cpp -v -undef -D__GNU__ -D__GNUC__ -Dsparc -Dsun -Dunix Convert.c /tmp/cca17790.cpp
GNU CPP version 1.31
/usr/local/lib/gcc-cc1 /tmp/cca17790.cpp -quiet -dumpbase Convert.c -g -version -o Convert.s
GNU C version 1.31 (sparc) compiled by GNU C version 1.31.
The offending assembler:
.stabn 68,0,43,LM11
LM11:
ld [%fp+84],%o0
ldd [%l1+28],%l4 <> 2) + from->size + *((char *) from->addr);
if (from->size > 1) hash += ((char *) from->addr)[1];
for (p = cacheHashTable[hash & 255 ]; p != 0 ; p = p->next) {
if ((p->hash == hash)
&& (p->converter == converter)
&& (p->from.size == from->size)
&& (p->num_args == num_args)) {
for (i = 0; i < num_args; i++) {
if ( p->args[i].size != args[i].size ) {
break;
}
}
if (i == num_args) {
(*to) = p->to;
return;
}
}
}
(*to).size = 0;
(*to).addr = 0 ;
(*converter)(args, &num_args, from, to);
CacheEnter(converter, args, num_args, from, to, hash);
}