Article View: gnu.gcc.bug
Article #187gcc2.2.2 on MIPS dies on unroll-loops
From: Olaf Flebbe
Date: Thu, 23 Jul 1992 08:30
Date: Thu, 23 Jul 1992 08:30
85 lines
2616 bytes
2616 bytes
Hello *,
I recently found a bug in gcc2.2.2 on several mips R3000
architectures: mips-sony-news, mips-sgi-irix4, mips-dec-ultrix.
Compiling the following piece of code (now senseless, because i tried to
cut it down to only a few lines; this is the shortest version I have)
with "gcc -O -funroll-loops -c neugit.c"
will yield:
----
neugit.c: In function `gitter':
neugit.c:35: internal error--unrecognizable insn:
(insn 440 438 361 (set (reg:SI 6)
(mem:SI (plus:SI (reg:SI 29)
(const_int 90120)))) -1 (nil)
(nil))
gcc: Internal compiler error: program cc1 got fatal signal 4
----
#!/bin/sh
# This is a shell archive (shar 3.46)
# made 07/23/1992 08:37 UTC by ???@nova
# Source directory /usr/wega/flebbe/tmp
#
# existing files will NOT be overwritten unless -c is specified
#
# This shar contains:
# length mode name
# ------ ---------- ------------------------------------------
# 579 -rw-r--r-- neugit.c
#
# ============= neugit.c ==============
if test -f 'neugit.c' -a X"$1" != X"-c"; then
echo 'x - skipping neugit.c (File already exists)'
else
echo 'x - extracting neugit.c (Text)'
sed 's/^X//' << 'SHAR_EOF' > 'neugit.c' &&
#include <math.h>
#include <stdlib.h>
X
#define MAXGIT 150
X
typedef struct {
X double x, y;
} vector_t;
X
void gitter( int count, vector_t pos[],
X int *nww,
X double r, double *rho) {
X int i, j, miny, maxy, hy;
X float help, d;
X
X int gitt[MAXGIT][MAXGIT];
X
X int *data = (int *)malloc(count*sizeof(int));
X
X for (i = 0; i < count; i++) {
X rho[i] = 0.;
X }
X
X for (i = 1; i < count; i++) {
X for (hy = miny; hy<= maxy; hy++) {
X while(j >=0) {
X d = pos[i].y - pos[j].y;
X if ( d <= r) {
X d = sqrt( d);
X rho[i] += help;
X }
X }
X }
X }
}
X
SHAR_EOF
chmod 0644 neugit.c ||
echo 'restore of neugit.c failed'
Wc_c="`wc -c < 'neugit.c'`"
test 579 -eq "$Wc_c" ||
echo 'neugit.c: original size 579, current size' "$Wc_c"
fi
exit 0
--
Olaf Flebbe, Theoretische Astrophysik Tuebingen
Internet: flebbe@tat.physik.uni-tuebingen.de
Technical Details
Message-ID:
<flebbe.711880224@wega>Path:
arc1-ca.pugleaf.net!sparky!uunet!cis.ohio-state.edu!wega.tat.physik.uni-tuebingen.de!flebbeShow Full Headers
Complete Article Headers
Newsgroups: gnu.gcc.bug Path: arc1-ca.pugleaf.net!sparky!uunet!cis.ohio-state.edu!wega.tat.physik.uni-tuebingen.de!flebbe From: flebbe@wega.tat.physik.uni-tuebingen.de (Olaf Flebbe) Subject: gcc2.2.2 on MIPS dies on unroll-loops Message-ID: <flebbe.711880224@wega> Sender: gnulists@ai.mit.edu Organization: TAT (Theoretical Astrophysics Tuebingen), U. of Tuebingen, FRG Distribution: gnu Date: Thu, 23 Jul 1992 08:30:24 GMT Approved: bug-gcc@prep.ai.mit.edu Lines: 86