This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH] Harden variably_modified_type_p
- From: Eric Botcazou <ebotcazou at adacore dot com>
- To: Richard Biener <rguenther at suse dot de>
- Cc: gcc-patches at gcc dot gnu dot org
- Date: Thu, 17 Aug 2017 18:26:16 +0200
- Subject: Re: [PATCH] Harden variably_modified_type_p
- Authentication-results: sourceware.org; auth=none
- References: <alpine.LSU.2.20.1708171654160.14191@zhemvz.fhfr.qr>
> It seems with Ada one can have cycles in types via pointer types
> and calling variably_modified_type_p on such type recurses indefinitely.
> The following is an attempt to fix that (albeit I'm not 100% sure
> there's no caller of the function using TREE_VISITED itself).
>
> Cures c38102a.adb with LTO early debug patches for me.
>
> Any comments? (no further testing sofar)
See walk_type_fields for a different approach to the same isse.
--
Eric Botcazou