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]

[Bug c/17750] New: Program does not compile with -O3


/*
Reading specs from /usr/lib/gcc/i686-pc-linux-gnu/3.4.0/specs
Configured with: ./configure -prefix=/usr
Thread model: posix
gcc version 3.4.0

program compiled on AMD 64 running Slackware 10.

program compiled with: gcc -O3 -c

Compiler Errors:
best.c: In function `wbest1':
best.c:24: error: prior parameter's size depends on 'numin'
best.c:24: error: prior parameter's size depends on 'numin'
best.c:24: error: prior parameter's size depends on 'numin'
best.c:24: error: prior parameter's size depends on 'numin'
best.c:24: error: prior parameter's size depends on 'numin'
best.c:24: error: prior parameter's size depends on 'numin'

Using --save-temps, here is best.i
------------------------------------------------------------
# 1 "best.c"
# 1 "<built-in>"
# 1 "<command line>"
# 1 "best.c"
# 25 "best.c"
void wbest1(numin,mat,tam,eig,ist)
int numin;
double mat[numin][numin],tam[numin][numin],eig[numin][numin];
int ist;
{
}

void wb(numin,mat,tam,eig,ist)
int numin;
double mat[numin][numin],tam[numin][numin],eig[numin][numin];
int ist;
{
}
------------------------------------------------------------

Here is best.s:
------------------------------------------------------------
        .file   "best.c"
        .section        .note.GNU-stack,"",@progbits
        .ident  "GCC: (GNU) 3.4.0"
------------------------------------------------------------



*/





void wbest1(numin,mat,tam,eig,ist)
int numin;
double mat[numin][numin],tam[numin][numin],eig[numin][numin];
int ist;
{
}

void wb(numin,mat,tam,eig,ist)
int numin;
double mat[numin][numin],tam[numin][numin],eig[numin][numin];
int ist;
{
}

-- 
           Summary: Program does not compile with -O3
           Product: gcc
           Version: 3.4.0
            Status: UNCONFIRMED
          Severity: critical
          Priority: P3
         Component: c
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: bashley at myrealbox dot com
                CC: bashley at myrealbox dot com,gcc-bugs at gcc dot gnu dot
                    org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17750


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