diff options
author | Thomas Koenig <tkoenig@gcc.gnu.org> | 2017-05-10 15:45:52 +0000 |
---|---|---|
committer | Thomas Koenig <tkoenig@gcc.gnu.org> | 2017-05-10 15:45:52 +0000 |
commit | 8e5f30dca07ebd8c2b2c335a61124931d9c9da10 (patch) | |
tree | c52d4c2267ca1cc79cde1031424c102b1329a417 /libgfortran/generated/matmul_c8.c | |
parent | a997fff52886be8c59f886376003539634e4781a (diff) | |
download | gcc-8e5f30dca07ebd8c2b2c335a61124931d9c9da10.zip gcc-8e5f30dca07ebd8c2b2c335a61124931d9c9da10.tar.gz gcc-8e5f30dca07ebd8c2b2c335a61124931d9c9da10.tar.bz2 |
re PR target/80687 (VLA usage in libgfortran; nvptx target: "sorry, unimplemented: target cannot support alloca")
2017-05-10 Thomas Koenig <tkoenig@gcc.gnu.org>
PR fortran/80687
PR fortran/80696
* m4/matmul_internal.m4: 'matmul_name`: Always
use malloc/free to allocate t1.
* generated/matmul_c10.c: Regenerated.
* generated/matmul_c16.c: Regenerated.
* generated/matmul_c4.c: Regenerated.
* generated/matmul_c8.c: Regenerated.
* generated/matmul_i1.c: Regenerated.
* generated/matmul_i16.c: Regenerated.
* generated/matmul_i2.c: Regenerated.
* generated/matmul_i4.c: Regenerated.
* generated/matmul_i8.c: Regenerated.
* generated/matmul_r10.c: Regenerated.
* generated/matmul_r16.c: Regenerated.
* generated/matmul_r4.c: Regenerated.
* generated/matmul_r8.c: Regenerated.
From-SVN: r247839
Diffstat (limited to 'libgfortran/generated/matmul_c8.c')
-rw-r--r-- | libgfortran/generated/matmul_c8.c | 35 |
1 files changed, 15 insertions, 20 deletions
diff --git a/libgfortran/generated/matmul_c8.c b/libgfortran/generated/matmul_c8.c index aafa3be..89153b2 100644 --- a/libgfortran/generated/matmul_c8.c +++ b/libgfortran/generated/matmul_c8.c @@ -290,6 +290,7 @@ matmul_c8_avx (gfc_array_c8 * const restrict retarray, f13, f14, f23, f24, f33, f34, f43, f44; index_type i, j, l, ii, jj, ll; index_type isec, jsec, lsec, uisec, ujsec, ulsec; + GFC_COMPLEX_8 *t1; a = abase; b = bbase; @@ -316,10 +317,7 @@ matmul_c8_avx (gfc_array_c8 * const restrict retarray, if (t1_dim > 65536) t1_dim = 65536; -#pragma GCC diagnostic push -#pragma GCC diagnostic ignored "-Wvla" - GFC_COMPLEX_8 t1[t1_dim]; /* was [256][256] */ -#pragma GCC diagnostic pop + t1 = malloc (t1_dim * sizeof(GFC_COMPLEX_8)); /* Empty c first. */ for (j=1; j<=n; j++) @@ -535,6 +533,7 @@ matmul_c8_avx (gfc_array_c8 * const restrict retarray, } } } + free(t1); return; } else if (rxstride == 1 && aystride == 1 && bxstride == 1) @@ -843,6 +842,7 @@ matmul_c8_avx2 (gfc_array_c8 * const restrict retarray, f13, f14, f23, f24, f33, f34, f43, f44; index_type i, j, l, ii, jj, ll; index_type isec, jsec, lsec, uisec, ujsec, ulsec; + GFC_COMPLEX_8 *t1; a = abase; b = bbase; @@ -869,10 +869,7 @@ matmul_c8_avx2 (gfc_array_c8 * const restrict retarray, if (t1_dim > 65536) t1_dim = 65536; -#pragma GCC diagnostic push -#pragma GCC diagnostic ignored "-Wvla" - GFC_COMPLEX_8 t1[t1_dim]; /* was [256][256] */ -#pragma GCC diagnostic pop + t1 = malloc (t1_dim * sizeof(GFC_COMPLEX_8)); /* Empty c first. */ for (j=1; j<=n; j++) @@ -1088,6 +1085,7 @@ matmul_c8_avx2 (gfc_array_c8 * const restrict retarray, } } } + free(t1); return; } else if (rxstride == 1 && aystride == 1 && bxstride == 1) @@ -1396,6 +1394,7 @@ matmul_c8_avx512f (gfc_array_c8 * const restrict retarray, f13, f14, f23, f24, f33, f34, f43, f44; index_type i, j, l, ii, jj, ll; index_type isec, jsec, lsec, uisec, ujsec, ulsec; + GFC_COMPLEX_8 *t1; a = abase; b = bbase; @@ -1422,10 +1421,7 @@ matmul_c8_avx512f (gfc_array_c8 * const restrict retarray, if (t1_dim > 65536) t1_dim = 65536; -#pragma GCC diagnostic push -#pragma GCC diagnostic ignored "-Wvla" - GFC_COMPLEX_8 t1[t1_dim]; /* was [256][256] */ -#pragma GCC diagnostic pop + t1 = malloc (t1_dim * sizeof(GFC_COMPLEX_8)); /* Empty c first. */ for (j=1; j<=n; j++) @@ -1641,6 +1637,7 @@ matmul_c8_avx512f (gfc_array_c8 * const restrict retarray, } } } + free(t1); return; } else if (rxstride == 1 && aystride == 1 && bxstride == 1) @@ -1945,6 +1942,7 @@ matmul_c8_vanilla (gfc_array_c8 * const restrict retarray, f13, f14, f23, f24, f33, f34, f43, f44; index_type i, j, l, ii, jj, ll; index_type isec, jsec, lsec, uisec, ujsec, ulsec; + GFC_COMPLEX_8 *t1; a = abase; b = bbase; @@ -1971,10 +1969,7 @@ matmul_c8_vanilla (gfc_array_c8 * const restrict retarray, if (t1_dim > 65536) t1_dim = 65536; -#pragma GCC diagnostic push -#pragma GCC diagnostic ignored "-Wvla" - GFC_COMPLEX_8 t1[t1_dim]; /* was [256][256] */ -#pragma GCC diagnostic pop + t1 = malloc (t1_dim * sizeof(GFC_COMPLEX_8)); /* Empty c first. */ for (j=1; j<=n; j++) @@ -2190,6 +2185,7 @@ matmul_c8_vanilla (gfc_array_c8 * const restrict retarray, } } } + free(t1); return; } else if (rxstride == 1 && aystride == 1 && bxstride == 1) @@ -2552,6 +2548,7 @@ matmul_c8 (gfc_array_c8 * const restrict retarray, f13, f14, f23, f24, f33, f34, f43, f44; index_type i, j, l, ii, jj, ll; index_type isec, jsec, lsec, uisec, ujsec, ulsec; + GFC_COMPLEX_8 *t1; a = abase; b = bbase; @@ -2578,10 +2575,7 @@ matmul_c8 (gfc_array_c8 * const restrict retarray, if (t1_dim > 65536) t1_dim = 65536; -#pragma GCC diagnostic push -#pragma GCC diagnostic ignored "-Wvla" - GFC_COMPLEX_8 t1[t1_dim]; /* was [256][256] */ -#pragma GCC diagnostic pop + t1 = malloc (t1_dim * sizeof(GFC_COMPLEX_8)); /* Empty c first. */ for (j=1; j<=n; j++) @@ -2797,6 +2791,7 @@ matmul_c8 (gfc_array_c8 * const restrict retarray, } } } + free(t1); return; } else if (rxstride == 1 && aystride == 1 && bxstride == 1) |