Fortran Testcase: subroutine sub(a, b, c, n); dimension a(n), b(n), c(n); if (n<=0) return;c = a + b; end
C testcase: int a[1000], b[1000], c[1000]; void sub (int n) { if (n <= 0) return; int i = 1; do { a[i-1] = b[i-1]+c[i-1]; i++; } while (i <= n); } --------- t.c:11: note: not vectorized: number of iterations cannot be computed. t.f90:1: note: not vectorized: number of iterations cannot be computed. -- Summary: Not vectorizing F90 array expressions Product: gcc Version: 4.2.0 Status: UNCONFIRMED Keywords: missed-optimization Severity: normal Priority: P3 Component: tree-optimization AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: pinskia at gcc dot gnu dot org http://gcc.gnu.org/bugzilla/show_bug.cgi?id=25644