aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEric Botcazou <ebotcazou@adacore.com>2017-11-23 22:55:05 +0000
committerEric Botcazou <ebotcazou@gcc.gnu.org>2017-11-23 22:55:05 +0000
commit773076a5129ce42e8865188fd0cae7617876006e (patch)
tree9d1dfd58545ec36581ee5a407b7e9596ae8c4445
parentd69f1ec7d19f3770450a6215395073dd911e5d20 (diff)
downloadgcc-773076a5129ce42e8865188fd0cae7617876006e.zip
gcc-773076a5129ce42e8865188fd0cae7617876006e.tar.gz
gcc-773076a5129ce42e8865188fd0cae7617876006e.tar.bz2
re PR ada/83091 (ICE with -g in arm-eabi compilation)
PR ada/83091 * gcc-interface/decl.c (gnat_to_gnu_entity): Do not build a variant type for the implementation type of a packed array. From-SVN: r255125
-rw-r--r--gcc/ada/ChangeLog6
-rw-r--r--gcc/ada/gcc-interface/decl.c6
2 files changed, 11 insertions, 1 deletions
diff --git a/gcc/ada/ChangeLog b/gcc/ada/ChangeLog
index 5a40cc1..bf899e2 100644
--- a/gcc/ada/ChangeLog
+++ b/gcc/ada/ChangeLog
@@ -1,3 +1,9 @@
+2017-11-23 Eric Botcazou <ebotcazou@adacore.com>
+
+ PR ada/83091
+ * gcc-interface/decl.c (gnat_to_gnu_entity): Do not build a variant
+ type for the implementation type of a packed array.
+
2017-11-23 Mike Stump <mikestump@comcast.net>
Eric Botcazou <ebotcazou@adacore.com>
diff --git a/gcc/ada/gcc-interface/decl.c b/gcc/ada/gcc-interface/decl.c
index e0d7a5f..77515c0 100644
--- a/gcc/ada/gcc-interface/decl.c
+++ b/gcc/ada/gcc-interface/decl.c
@@ -4568,7 +4568,11 @@ gnat_to_gnu_entity (Entity_Id gnat_entity, tree gnu_expr, bool definition)
? ALIAS_SET_COPY : ALIAS_SET_SUPERSET);
}
- if (Treat_As_Volatile (gnat_entity))
+ /* Finally get to the appropriate variant, except for the implementation
+ type of a packed array because the GNU type might be further adjusted
+ when the original array type is itself processed. */
+ if (Treat_As_Volatile (gnat_entity)
+ && !Is_Packed_Array_Impl_Type (gnat_entity))
{
const int quals
= TYPE_QUAL_VOLATILE