This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

other/9081: gcc doesn't diagnose, that the compiler exceeds a compiler limit


>Number:         9081
>Category:       other
>Synopsis:       gcc doesn't diagnose, that the compiler exceeds a compiler limit
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    unassigned
>State:          open
>Class:          accepts-illegal
>Submitter-Id:   net
>Arrival-Date:   Sat Dec 28 06:06:00 PST 2002
>Closed-Date:
>Last-Modified:
>Originator:     Pavel Machek <pavel@atrey.karlin.mff.cuni.cz>
>Release:        3.2.1 (Debian) (Debian unstable)
>Organization:
The Debian Project
>Environment:
System: Debian GNU/Linux (unstable)
Architecture: i686
host: i386-linux
Configured with: ../src/configure -v --enable-languages=c,c++,java,f77,proto,pascal,objc,ada --prefix=/usr --mandir=/usr/share/man --infodir=/usr/share/info --with-gxx-include-dir=/usr/include/c++/3.2 --enable-shared --with-system-zlib --enable-nls --without-included-gettext --enable-__cxa_atexit --enable-clocale=gnu --enable-java-gc=boehm --enable-objc-gc i386-linux
Thread model: posix
gcc version 3.2.2 20021212 (Debian prerelease)
>Description:
[ Reported to the Debian BTS as report #133574.
  Please CC 133574@bugs.debian.org on replies.
  Log of report can be found at http://bugs.debian.org/133574 ]
	

The following buggy code is exceeding a compiler limit,
thus the code behaves undefined. There is a bug in the compiler also:
the compiler should diagnose that you exceed the limit, but there is
no reasonable way you could expect this code to work on the
microprocessor you are using (and with the operating system you are
using).

#define MAXLEN 20
#define MAXTAG 10
double speedup[MAXLEN][MAXLEN][MAXLEN][MAXLEN][MAXTAG][MAXTAG][MAXTAG];

void
init_speedup(void)
{
    int i, j, k, l, o, m, n;
    for (i=0; i<MAXLEN; i++)
        for (j=0; j<MAXLEN; j++)
            for (k=0; k<MAXLEN; k++)
                for (l=0; l<MAXLEN; l++)
                    for (o=0; o<MAXTAG; o++)
                        for (m=0; m<MAXTAG; m++)
                            for (n=0; n<MAXTAG; n++)
                                speedup[i][j][k][l][o][m][n] = -1.0;
}

int main(void)
{
    init_speedup();
    return 0;
}
>How-To-Repeat:
	
>Fix:
	
>Release-Note:
>Audit-Trail:
>Unformatted:


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]