From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 2100) id 812C63894C30; Sat, 22 Aug 2020 21:33:11 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 812C63894C30 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1598131991; bh=0nesp9m+0lOLUQTbgx749rSavC7m1BYG4d6YkdUjLSE=; h=From:To:Subject:Date:From; b=euB2vlTfw/fpa5mWVtRXiYOApscTNko1GIlqRBoIE6zMqGI/tXaFQkv2jG+TQJSZd wNQXhw8UKcl74dCjiGGO2wb986f+KQoGQo9WPAPR/g3NAUW3U0pIG8VNlHWXfEoljW 4GWDZ7Cz1nEp/ZLct6tEN+oIhk9Qv9WJMmdrprFA= Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: Giuliano Belinassi To: gcc-cvs@gcc.gnu.org Subject: [gcc/devel/autopar_devel] Fix small fallout of earlier change X-Act-Checkin: gcc X-Git-Author: Eric Botcazou X-Git-Refname: refs/heads/devel/autopar_devel X-Git-Oldrev: 0ee8729e60dbc048c2bb82f906aa3b7adc61d216 X-Git-Newrev: f73b5fa1bbe45d59049157d08d3fe83576216cd8 Message-Id: <20200822213311.812C63894C30@sourceware.org> Date: Sat, 22 Aug 2020 21:33:11 +0000 (GMT) X-BeenThere: gcc-cvs@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-cvs mailing list List-Unsubscribe: , List-Archive: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 22 Aug 2020 21:33:11 -0000 https://gcc.gnu.org/g:f73b5fa1bbe45d59049157d08d3fe83576216cd8 commit f73b5fa1bbe45d59049157d08d3fe83576216cd8 Author: Eric Botcazou Date: Mon May 25 10:32:21 2020 +0200 Fix small fallout of earlier change gcc/ada/ChangeLog * gcc-interface/misc.c (get_array_bit_stride): Get to the debug type, if any, before calling gnat_get_array_descr_info. Diff: --- gcc/ada/ChangeLog | 5 +++++ gcc/ada/gcc-interface/misc.c | 3 +++ 2 files changed, 8 insertions(+) diff --git a/gcc/ada/ChangeLog b/gcc/ada/ChangeLog index 769728af854..d2020b8894c 100644 --- a/gcc/ada/ChangeLog +++ b/gcc/ada/ChangeLog @@ -1,3 +1,8 @@ +2020-05-25 Eric Botcazou + + * gcc-interface/misc.c (get_array_bit_stride): Get to the debug type, + if any, before calling gnat_get_array_descr_info. + 2020-05-25 Eric Botcazou * gcc-interface/decl.c (gnat_to_gnu_entity) : Tidy up. diff --git a/gcc/ada/gcc-interface/misc.c b/gcc/ada/gcc-interface/misc.c index 5a5850a85e0..f8fa8563161 100644 --- a/gcc/ada/gcc-interface/misc.c +++ b/gcc/ada/gcc-interface/misc.c @@ -1003,6 +1003,9 @@ get_array_bit_stride (tree comp_type) if (INTEGRAL_TYPE_P (comp_type)) return TYPE_RM_SIZE (comp_type); + /* The gnat_get_array_descr_info debug hook expects a debug tyoe. */ + comp_type = maybe_debug_type (comp_type); + /* Otherwise, see if this is an array we can analyze; if it's not, punt. */ memset (&info, 0, sizeof (info)); if (!gnat_get_array_descr_info (comp_type, &info) || !info.stride)