re PR libfortran/32972 (performance of pack/unpack)
authorThomas Koenig <tkoenig@gcc.gnu.org>
Sun, 13 Apr 2008 20:15:58 +0000 (20:15 +0000)
committerThomas Koenig <tkoenig@gcc.gnu.org>
Sun, 13 Apr 2008 20:15:58 +0000 (20:15 +0000)
commitc7d0f4d5fabc279dd81330ebffdf037b31420706
treee022b93b7ac1c858cd02bc0f837fdaae49b136ff
parent92d4508a7db153423b0572047fa6947af569d4b6
re PR libfortran/32972 (performance of pack/unpack)

2008-04-13  Thomas Koenig  <tkoenig@gcc.gnu.org>
Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>

PR libfortran/32972
PR libfortran/32512
configure.ac:  Add test for uintptr_t.
configure:  Regenerated.
config.h.in:  Regenerated.
* libgfortran.h: GFC_DTYPE_DERIVED_1:  New macro.
GFC_DTYPE_DERIVED_2:  New macro.
GFC_DTYPE_DERIVED_4:  New macro.
GFC_DTYPE_DERIVED_8:  New macro.
GFC_DTYPE_DERIVED_16:  New macro.
GFC_UNALIGNED_2:  New macro.
GFC_UNALIGNED_4:  New macro.
GFC_UNALIGNED_8:  New macro.
GFC_UNALIGNED_16:  New macro.
intptr_t:  Define if we don't have it.
uintptr_t:  Likewise.
* runtime/backtrace.c (show_backtrace):  Use intptr_t.
* intrinsics/signal.c (signal_sub):  Likewise.
(signal_sub_int):  Likewise.
(alarm_sub_int_i4):  Likewise.
* intrinsics/spread_generic.c (spread):  Use the integer
routines for handling derived types of sizes 1, 2, 4, 8 and 16
if the alignment of all pointers is correct.
(spread_scalar):  Likewise.
* intrinsics/pack_generic.c (pack):  Likewise.
Use GFD_DTYPE_TYPE_SIZE to avoid nested switch statements.
* intrinsics/unpack_generic.c (unpack1):  Likewise.
(unpack0):  Likewise.
* runtime/in_pack_generic.c (internal_pack):  Likewise.
* runtime/in_unpack_generic.c (internal_unpack):  Likewise.

2008-04-13  Thomas Koenig  <tkoenig@gcc.gnu.org>

PR libfortran/32972
PR libfortran/32512
* gfortran.dg/internal_pack_1.f90:  Add test for derived type.
* gfortran.dg/intrinsic_spread_1.f90:  Likewise.
* gfortran.dg/intrinsic_pack_1.f90:  Likewise.
* gfortran.dg/intrinsic_unpack_1.f90:  Likewise.

Co-Authored-By: Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
From-SVN: r134245
17 files changed:
gcc/testsuite/ChangeLog
gcc/testsuite/gfortran.dg/internal_pack_1.f90
gcc/testsuite/gfortran.dg/intrinsic_pack_1.f90
gcc/testsuite/gfortran.dg/intrinsic_spread_1.f90
gcc/testsuite/gfortran.dg/intrinsic_unpack_1.f90
libgfortran/ChangeLog
libgfortran/config.h.in
libgfortran/configure
libgfortran/configure.ac
libgfortran/intrinsics/pack_generic.c
libgfortran/intrinsics/signal.c
libgfortran/intrinsics/spread_generic.c
libgfortran/intrinsics/unpack_generic.c
libgfortran/libgfortran.h
libgfortran/runtime/backtrace.c
libgfortran/runtime/in_pack_generic.c
libgfortran/runtime/in_unpack_generic.c