diff options
author | Thomas Koenig <tkoenig@gcc.gnu.org> | 2017-06-24 07:07:56 +0000 |
---|---|---|
committer | Thomas Koenig <tkoenig@gcc.gnu.org> | 2017-06-24 07:07:56 +0000 |
commit | e56e3fda6092548f3cd5336d131b412be986b1e6 (patch) | |
tree | 2c28733ee096cbdb641e42b511b18f7c28205330 /libgfortran/libgfortran.h | |
parent | ef5b7d19b688bb92178f41f504133f0ee51bffc6 (diff) | |
download | gcc-e56e3fda6092548f3cd5336d131b412be986b1e6.tar.gz |
re PR fortran/52473 (CSHIFT slow - inline it?)
2017-06-24 Thomas Koenig <tkoenig@gcc.gnu.org>
PR fortran/52473
* Makefile.am: Add i_cshift1a_c. Add rules to generate files
from cshift1a.m4.
* Makefile.in: Regenerated.
* m4/cshift1a.m4: New file.
* m4/cshift.m4 (cshift1): Split up inner loop by removing
condition. Use memcpy where possible. Call helper functions
based on dtype.
* libgfortran.h: Add prototypes for cshift1_16_c10,
cshift1_16_c16, cshift1_16_c4, cshift1_16_c8, cshift1_16_i1,
cshift1_16_i16, cshift1_16_i2, cshift1_16_i4, cshift1_16_i8,
cshift1_16_r10, cshift1_16_r16, cshift1_16_r4, cshift1_16_r8,
cshift1_4_c10, cshift1_4_c16, cshift1_4_c4, cshift1_4_c8,
cshift1_4_i1, cshift1_4_i16, cshift1_4_i2, cshift1_4_i4,
cshift1_4_i8, cshift1_4_r10, cshift1_4_r16, cshift1_4_r4,
cshift1_4_r8, cshift1_8_c10, cshift1_8_c16, cshift1_8_c4,
cshift1_8_c8, cshift1_8_i1, cshift1_8_i16, cshift1_8_i2,
cshift1_8_i4, cshift1_8_i8, cshift1_8_r10, cshift1_8_r16,
cshift1_8_r4 and cshift1_8_r8.
* generated/cshift1_16_c10.c: New file, generated from cshift1a.m4.
* generated/cshift1_16_c16.c: New file, generated from cshift1a.m4.
* generated/cshift1_16_c4.c: New file, generated from cshift1a.m4.
* generated/cshift1_16_c8.c: New file, generated from cshift1a.m4.
* generated/cshift1_16_i1.c: New file, generated from cshift1a.m4.
* generated/cshift1_16_i16.c: New file, generated from cshift1a.m4.
* generated/cshift1_16_i2.c: New file, generated from cshift1a.m4.
* generated/cshift1_16_i4.c: New file, generated from cshift1a.m4.
* generated/cshift1_16_i8.c: New file, generated from cshift1a.m4.
* generated/cshift1_16_r10.c: New file, generated from cshift1a.m4.
* generated/cshift1_16_r16.c: New file, generated from cshift1a.m4.
* generated/cshift1_16_r4.c: New file, generated from cshift1a.m4.
* generated/cshift1_16_r8.c: New file, generated from cshift1a.m4.
* generated/cshift1_4_c10.c: New file, generated from cshift1a.m4.
* generated/cshift1_4_c16.c: New file, generated from cshift1a.m4.
* generated/cshift1_4_c4.c: New file, generated from cshift1a.m4.
* generated/cshift1_4_c8.c: New file, generated from cshift1a.m4.
* generated/cshift1_4_i1.c: New file, generated from cshift1a.m4.
* generated/cshift1_4_i16.c: New file, generated from cshift1a.m4.
* generated/cshift1_4_i2.c: New file, generated from cshift1a.m4.
* generated/cshift1_4_i4.c: New file, generated from cshift1a.m4.
* generated/cshift1_4_i8.c: New file, generated from cshift1a.m4.
* generated/cshift1_4_r10.c: New file, generated from cshift1a.m4.
* generated/cshift1_4_r16.c: New file, generated from cshift1a.m4.
* generated/cshift1_4_r4.c: New file, generated from cshift1a.m4.
* generated/cshift1_4_r8.c: New file, generated from cshift1a.m4.
* generated/cshift1_8_c10.c: New file, generated from cshift1a.m4.
* generated/cshift1_8_c16.c: New file, generated from cshift1a.m4.
* generated/cshift1_8_c4.c: New file, generated from cshift1a.m4.
* generated/cshift1_8_c8.c: New file, generated from cshift1a.m4.
* generated/cshift1_8_i1.c: New file, generated from cshift1a.m4.
* generated/cshift1_8_i16.c: New file, generated from cshift1a.m4.
* generated/cshift1_8_i2.c: New file, generated from cshift1a.m4.
* generated/cshift1_8_i4.c: New file, generated from cshift1a.m4.
* generated/cshift1_8_i8.c: New file, generated from cshift1a.m4.
* generated/cshift1_8_r10.c: New file, generated from cshift1a.m4.
* generated/cshift1_8_r16.c: New file, generated from cshift1a.m4.
* generated/cshift1_8_r4.c: New file, generated from cshift1a.m4.
* generated/cshift1_8_r8.c: New file, generated from cshift1a.m4.
2017-06-24 Thomas Koenig <tkoenig@gcc.gnu.org>
PR fortran/52473
* gfortran.dg/cshift_2.f90: New test.
From-SVN: r249620
Diffstat (limited to 'libgfortran/libgfortran.h')
-rw-r--r-- | libgfortran/libgfortran.h | 313 |
1 files changed, 313 insertions, 0 deletions
diff --git a/libgfortran/libgfortran.h b/libgfortran/libgfortran.h index 9d9d11728bd..22f412357a7 100644 --- a/libgfortran/libgfortran.h +++ b/libgfortran/libgfortran.h @@ -1418,4 +1418,317 @@ void cshift0_c16 (gfc_array_c16 *, const gfc_array_c16 *, ptrdiff_t, int); internal_proto(cshift0_c16); #endif +#if defined (HAVE_GFC_INTEGER_4) && defined (HAVE_GFC_INTEGER_1) +void cshift1_4_i1 (gfc_array_i1 * const restrict, + const gfc_array_i1 * const restrict, + const gfc_array_i4 * const restrict, + const GFC_INTEGER_4 * const restrict); +internal_proto(cshift1_4_i1); +#endif + +#if defined (HAVE_GFC_INTEGER_4) && defined (HAVE_GFC_INTEGER_2) +void cshift1_4_i2 (gfc_array_i2 * const restrict, + const gfc_array_i2 * const restrict, + const gfc_array_i4 * const restrict, + const GFC_INTEGER_4 * const restrict); +internal_proto(cshift1_4_i2); +#endif + +#if defined (HAVE_GFC_INTEGER_4) && defined (HAVE_GFC_INTEGER_4) +void cshift1_4_i4 (gfc_array_i4 * const restrict, + const gfc_array_i4 * const restrict, + const gfc_array_i4 * const restrict, + const GFC_INTEGER_4 * const restrict); +internal_proto(cshift1_4_i4); +#endif + +#if defined (HAVE_GFC_INTEGER_4) && defined (HAVE_GFC_INTEGER_8) +void cshift1_4_i8 (gfc_array_i8 * const restrict, + const gfc_array_i8 * const restrict, + const gfc_array_i4 * const restrict, + const GFC_INTEGER_4 * const restrict); +internal_proto(cshift1_4_i8); +#endif + +#if defined (HAVE_GFC_INTEGER_4) && defined (HAVE_GFC_INTEGER_16) +void cshift1_4_i16 (gfc_array_i16 * const restrict, + const gfc_array_i16 * const restrict, + const gfc_array_i4 * const restrict, + const GFC_INTEGER_4 * const restrict); +internal_proto(cshift1_4_i16); +#endif + +#if defined (HAVE_GFC_INTEGER_8) && defined (HAVE_GFC_INTEGER_1) +void cshift1_8_i1 (gfc_array_i1 * const restrict, + const gfc_array_i1 * const restrict, + const gfc_array_i8 * const restrict, + const GFC_INTEGER_8 * const restrict); +internal_proto(cshift1_8_i1); +#endif + +#if defined (HAVE_GFC_INTEGER_8) && defined (HAVE_GFC_INTEGER_2) +void cshift1_8_i2 (gfc_array_i2 * const restrict, + const gfc_array_i2 * const restrict, + const gfc_array_i8 * const restrict, + const GFC_INTEGER_8 * const restrict); +internal_proto(cshift1_8_i2); +#endif + +#if defined (HAVE_GFC_INTEGER_8) && defined (HAVE_GFC_INTEGER_4) +void cshift1_8_i4 (gfc_array_i4 * const restrict, + const gfc_array_i4 * const restrict, + const gfc_array_i8 * const restrict, + const GFC_INTEGER_8 * const restrict); +internal_proto(cshift1_8_i4); +#endif + +#if defined (HAVE_GFC_INTEGER_8) && defined (HAVE_GFC_INTEGER_8) +void cshift1_8_i8 (gfc_array_i8 * const restrict, + const gfc_array_i8 * const restrict, + const gfc_array_i8 * const restrict, + const GFC_INTEGER_8 * const restrict); +internal_proto(cshift1_8_i8); +#endif + +#if defined (HAVE_GFC_INTEGER_8) && defined (HAVE_GFC_INTEGER_16) +void cshift1_8_i16 (gfc_array_i16 * const restrict, + const gfc_array_i16 * const restrict, + const gfc_array_i8 * const restrict, + const GFC_INTEGER_8 * const restrict); +internal_proto(cshift1_8_i16); +#endif + +#if defined (HAVE_GFC_INTEGER_16) && defined (HAVE_GFC_INTEGER_1) +void cshift1_16_i1 (gfc_array_i1 * const restrict, + const gfc_array_i1 * const restrict, + const gfc_array_i16 * const restrict, + const GFC_INTEGER_16 * const restrict); +internal_proto(cshift1_16_i1); +#endif + +#if defined (HAVE_GFC_INTEGER_16) && defined (HAVE_GFC_INTEGER_2) +void cshift1_16_i2 (gfc_array_i2 * const restrict, + const gfc_array_i2 * const restrict, + const gfc_array_i16 * const restrict, + const GFC_INTEGER_16 * const restrict); +internal_proto(cshift1_16_i2); +#endif + +#if defined (HAVE_GFC_INTEGER_16) && defined (HAVE_GFC_INTEGER_4) +void cshift1_16_i4 (gfc_array_i4 * const restrict, + const gfc_array_i4 * const restrict, + const gfc_array_i16 * const restrict, + const GFC_INTEGER_16 * const restrict); +internal_proto(cshift1_16_i4); +#endif + +#if defined (HAVE_GFC_INTEGER_16) && defined (HAVE_GFC_INTEGER_8) +void cshift1_16_i8 (gfc_array_i8 * const restrict, + const gfc_array_i8 * const restrict, + const gfc_array_i16 * const restrict, + const GFC_INTEGER_16 * const restrict); +internal_proto(cshift1_16_i8); +#endif + +#if defined (HAVE_GFC_INTEGER_16) && defined (HAVE_GFC_INTEGER_16) +void cshift1_16_i16 (gfc_array_i16 * const restrict, + const gfc_array_i16 * const restrict, + const gfc_array_i16 * const restrict, + const GFC_INTEGER_16 * const restrict); +internal_proto(cshift1_16_i16); +#endif + +#if defined (HAVE_GFC_INTEGER_4) && defined (HAVE_GFC_REAL_4) +void cshift1_4_r4 (gfc_array_r4 * const restrict, + const gfc_array_r4 * const restrict, + const gfc_array_i4 * const restrict, + const GFC_INTEGER_4 * const restrict); +internal_proto(cshift1_4_r4); +#endif + +#if defined (HAVE_GFC_INTEGER_4) && defined (HAVE_GFC_REAL_8) +void cshift1_4_r8 (gfc_array_r8 * const restrict, + const gfc_array_r8 * const restrict, + const gfc_array_i4 * const restrict, + const GFC_INTEGER_4 * const restrict); +internal_proto(cshift1_4_r8); +#endif + +#if defined (HAVE_GFC_INTEGER_4) && defined (HAVE_GFC_REAL_10) +void cshift1_4_r10 (gfc_array_r10 * const restrict, + const gfc_array_r10 * const restrict, + const gfc_array_i4 * const restrict, + const GFC_INTEGER_4 * const restrict); +internal_proto(cshift1_4_r10); +#endif + +#if defined (HAVE_GFC_INTEGER_4) && defined (HAVE_GFC_REAL_16) +void cshift1_4_r16 (gfc_array_r16 * const restrict, + const gfc_array_r16 * const restrict, + const gfc_array_i4 * const restrict, + const GFC_INTEGER_4 * const restrict); +internal_proto(cshift1_4_r16); +#endif + +#if defined (HAVE_GFC_INTEGER_8) && defined (HAVE_GFC_REAL_4) +void cshift1_8_r4 (gfc_array_r4 * const restrict, + const gfc_array_r4 * const restrict, + const gfc_array_i8 * const restrict, + const GFC_INTEGER_8 * const restrict); +internal_proto(cshift1_8_r4); +#endif + +#if defined (HAVE_GFC_INTEGER_8) && defined (HAVE_GFC_REAL_8) +void cshift1_8_r8 (gfc_array_r8 * const restrict, + const gfc_array_r8 * const restrict, + const gfc_array_i8 * const restrict, + const GFC_INTEGER_8 * const restrict); +internal_proto(cshift1_8_r8); +#endif + +#if defined (HAVE_GFC_INTEGER_8) && defined (HAVE_GFC_REAL_10) +void cshift1_8_r10 (gfc_array_r10 * const restrict, + const gfc_array_r10 * const restrict, + const gfc_array_i8 * const restrict, + const GFC_INTEGER_8 * const restrict); +internal_proto(cshift1_8_r10); +#endif + +#if defined (HAVE_GFC_INTEGER_8) && defined (HAVE_GFC_REAL_16) +void cshift1_8_r16 (gfc_array_r16 * const restrict, + const gfc_array_r16 * const restrict, + const gfc_array_i8 * const restrict, + const GFC_INTEGER_8 * const restrict); +internal_proto(cshift1_8_r16); +#endif + +#if defined (HAVE_GFC_INTEGER_16) && defined (HAVE_GFC_REAL_4) +void cshift1_16_r4 (gfc_array_r4 * const restrict, + const gfc_array_r4 * const restrict, + const gfc_array_i16 * const restrict, + const GFC_INTEGER_16 * const restrict); +internal_proto(cshift1_16_r4); +#endif + +#if defined (HAVE_GFC_INTEGER_16) && defined (HAVE_GFC_REAL_8) +void cshift1_16_r8 (gfc_array_r8 * const restrict, + const gfc_array_r8 * const restrict, + const gfc_array_i16 * const restrict, + const GFC_INTEGER_16 * const restrict); +internal_proto(cshift1_16_r8); +#endif + +#if defined (HAVE_GFC_INTEGER_16) && defined (HAVE_GFC_REAL_10) +void cshift1_16_r10 (gfc_array_r10 * const restrict, + const gfc_array_r10 * const restrict, + const gfc_array_i16 * const restrict, + const GFC_INTEGER_16 * const restrict); +internal_proto(cshift1_16_r10); +#endif + +#if defined (HAVE_GFC_INTEGER_16) && defined (HAVE_GFC_REAL_16) +void cshift1_16_r16 (gfc_array_r16 * const restrict, + const gfc_array_r16 * const restrict, + const gfc_array_i16 * const restrict, + const GFC_INTEGER_16 * const restrict); +internal_proto(cshift1_16_r16); +#endif + +#if defined (HAVE_GFC_INTEGER_4) && defined (HAVE_GFC_COMPLEX_4) +void cshift1_4_c4 (gfc_array_c4 * const restrict, + const gfc_array_c4 * const restrict, + const gfc_array_i4 * const restrict, + const GFC_INTEGER_4 * const restrict); +internal_proto(cshift1_4_c4); +#endif + +#if defined (HAVE_GFC_INTEGER_4) && defined (HAVE_GFC_COMPLEX_8) +void cshift1_4_c8 (gfc_array_c8 * const restrict, + const gfc_array_c8 * const restrict, + const gfc_array_i4 * const restrict, + const GFC_INTEGER_4 * const restrict); +internal_proto(cshift1_4_c8); +#endif + +#if defined (HAVE_GFC_INTEGER_4) && defined (HAVE_GFC_COMPLEX_10) +void cshift1_4_c10 (gfc_array_c10 * const restrict, + const gfc_array_c10 * const restrict, + const gfc_array_i4 * const restrict, + const GFC_INTEGER_4 * const restrict); +internal_proto(cshift1_4_c10); +#endif + +#if defined (HAVE_GFC_INTEGER_4) && defined (HAVE_GFC_COMPLEX_16) +void cshift1_4_c16 (gfc_array_c16 * const restrict, + const gfc_array_c16 * const restrict, + const gfc_array_i4 * const restrict, + const GFC_INTEGER_4 * const restrict); +internal_proto(cshift1_4_c16); +#endif + +#if defined (HAVE_GFC_INTEGER_8) && defined (HAVE_GFC_COMPLEX_4) +void cshift1_8_c4 (gfc_array_c4 * const restrict, + const gfc_array_c4 * const restrict, + const gfc_array_i8 * const restrict, + const GFC_INTEGER_8 * const restrict); +internal_proto(cshift1_8_c4); +#endif + +#if defined (HAVE_GFC_INTEGER_8) && defined (HAVE_GFC_COMPLEX_8) +void cshift1_8_c8 (gfc_array_c8 * const restrict, + const gfc_array_c8 * const restrict, + const gfc_array_i8 * const restrict, + const GFC_INTEGER_8 * const restrict); +internal_proto(cshift1_8_c8); +#endif + +#if defined (HAVE_GFC_INTEGER_8) && defined (HAVE_GFC_COMPLEX_10) +void cshift1_8_c10 (gfc_array_c10 * const restrict, + const gfc_array_c10 * const restrict, + const gfc_array_i8 * const restrict, + const GFC_INTEGER_8 * const restrict); +internal_proto(cshift1_8_c10); +#endif + +#if defined (HAVE_GFC_INTEGER_8) && defined (HAVE_GFC_COMPLEX_16) +void cshift1_8_c16 (gfc_array_c16 * const restrict, + const gfc_array_c16 * const restrict, + const gfc_array_i8 * const restrict, + const GFC_INTEGER_8 * const restrict); +internal_proto(cshift1_8_c16); +#endif + +#if defined (HAVE_GFC_INTEGER_16) && defined (HAVE_GFC_COMPLEX_4) +void cshift1_16_c4 (gfc_array_c4 * const restrict, + const gfc_array_c4 * const restrict, + const gfc_array_i16 * const restrict, + const GFC_INTEGER_16 * const restrict); +internal_proto(cshift1_16_c4); +#endif + +#if defined (HAVE_GFC_INTEGER_16) && defined (HAVE_GFC_COMPLEX_8) +void cshift1_16_c8 (gfc_array_c8 * const restrict, + const gfc_array_c8 * const restrict, + const gfc_array_i16 * const restrict, + const GFC_INTEGER_16 * const restrict); +internal_proto(cshift1_16_c8); +#endif + +#if defined (HAVE_GFC_INTEGER_16) && defined (HAVE_GFC_COMPLEX_10) +void cshift1_16_c10 (gfc_array_c10 * const restrict, + const gfc_array_c10 * const restrict, + const gfc_array_i16 * const restrict, + const GFC_INTEGER_16 * const restrict); +internal_proto(cshift1_16_c10); +#endif + +#if defined (HAVE_GFC_INTEGER_16) && defined (HAVE_GFC_COMPLEX_16) +void cshift1_16_c16 (gfc_array_c16 * const restrict, + const gfc_array_c16 * const restrict, + const gfc_array_i16 * const restrict, + const GFC_INTEGER_16 * const restrict); +internal_proto(cshift1_16_c16); +#endif + + #endif /* LIBGFOR_H */ |