diff options
author | Jan Hubicka <hubicka@ucw.cz> | 2015-06-09 00:24:57 +0200 |
---|---|---|
committer | Jan Hubicka <hubicka@gcc.gnu.org> | 2015-06-08 22:24:57 +0000 |
commit | 64578d988427290be041802901a005b61cebf95a (patch) | |
tree | 35be7a92fc2dbe146f3c69e913968b9856f0f396 /gcc/lto | |
parent | 44433db051a923a6e32baa8e448ec8cf5a88f5f8 (diff) | |
download | gcc-64578d988427290be041802901a005b61cebf95a.zip gcc-64578d988427290be041802901a005b61cebf95a.tar.gz gcc-64578d988427290be041802901a005b61cebf95a.tar.bz2 |
lto.c (hash_canonical_type): Drop hashing of TYPE_STRING_FLAG.
* lto.c (hash_canonical_type): Drop hashing of TYPE_STRING_FLAG.
* tree.c (gimple_canonical_types_compatible_p): Drop comparsion of
TYPE_STRING_FLAG.
* gfortran.dg/lto/bind_c-2b_0.f90: New testcase
* gfortran.dg/lto/bind_c-2b_1.c: New testcase
From-SVN: r224252
Diffstat (limited to 'gcc/lto')
-rw-r--r-- | gcc/lto/ChangeLog | 4 | ||||
-rw-r--r-- | gcc/lto/lto.c | 12 |
2 files changed, 9 insertions, 7 deletions
diff --git a/gcc/lto/ChangeLog b/gcc/lto/ChangeLog index 86771fe..5d0e888 100644 --- a/gcc/lto/ChangeLog +++ b/gcc/lto/ChangeLog @@ -1,3 +1,7 @@ +2015-06-08 Jan Hubicka <hubicka@ucw.cz> + + * lto.c (hash_canonical_type): Drop hashing of TYPE_STRING_FLAG. + 2015-06-08 Andrew MacLeod <amacleod@redhat.com> * lto-lang.c : Adjust include files. diff --git a/gcc/lto/lto.c b/gcc/lto/lto.c index b8e73cd..b9b1110 100644 --- a/gcc/lto/lto.c +++ b/gcc/lto/lto.c @@ -332,17 +332,15 @@ hash_canonical_type (tree type) if (TREE_CODE (type) == COMPLEX_TYPE) hstate.add_int (TYPE_UNSIGNED (type)); + /* Fortran's C_SIGNED_CHAR is !TYPE_STRING_FLAG but needs to be + interoperable with "signed char". Unless all frontends are revisited to + agree on these types, we must ignore the flag completely. */ + /* Fortran standard define C_PTR type that is compatible with every C pointer. For this reason we need to glob all pointers into one. Still pointers in different address spaces are not compatible. */ if (POINTER_TYPE_P (type)) - { - hstate.add_int (TYPE_ADDR_SPACE (TREE_TYPE (type))); - } - - /* For integer types hash only the string flag. */ - if (TREE_CODE (type) == INTEGER_TYPE) - hstate.add_int (TYPE_STRING_FLAG (type)); + hstate.add_int (TYPE_ADDR_SPACE (TREE_TYPE (type))); /* For array types hash the domain bounds and the string flag. */ if (TREE_CODE (type) == ARRAY_TYPE && TYPE_DOMAIN (type)) |