This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: fix for segmentation violation in dump_generic_node
- From: Richard Guenther <richard dot guenther at gmail dot com>
- To: Tom de Vries <vries at codesourcery dot com>
- Cc: Jakub Jelinek <jakub at redhat dot com>, "gcc-patches at gcc dot gnu dot org" <gcc-patches at gcc dot gnu dot org>
- Date: Thu, 25 Aug 2011 12:45:55 +0200
- Subject: Re: fix for segmentation violation in dump_generic_node
- References: <4E5624B6.3080005@codesourcery.com>
On Thu, Aug 25, 2011 at 12:32 PM, Tom de Vries <vries@codesourcery.com> wrote:
> Jakub,
>
> This patch fixes a segmentation violation, which occurs when printing a MEM_REF
> or COMPONENT_REF containing a released ssa name. ?This can happen when we print
> basic blocks upon removal, enabled by -ftree-dump-tree-*-details (see
> remove_bb:tree-cfg.c).
Where do we dump stmts there?
> Bootstrapped and reg-tested on x86_64.
>
> OK for trunk?
At least
TREE_TYPE (TREE_OPERAND (node, 1)) != NULL_TREE
is always true.
The comment before the new lines is now in the wrong place and this
check at least needs a comment as well.
But - it's broken to dump freed stuff, why and where do we do this?
Richard.
> Thanks,
> - Tom
>
> 2011-08-25 ?Tom de Vries ?<tom@codesourcery.com>
>
> ? ? ? ?* tree-pretty-print (dump_generic_node): Test for NULL_TREE before
> ? ? ? ?accessing TREE_TYPE.
>