From bf3892af752e5a8db9f127808337ac448d9c6e65 Mon Sep 17 00:00:00 2001 From: Jan Hubicka Date: Sun, 4 Feb 2007 18:58:26 +0100 Subject: [PATCH] tree-sra.c (sra_walk_expr): Add linebreaks. * tree-sra.c (sra_walk_expr): Add linebreaks. BITFIELD_REFs into vectors might cause maybe_lookup_element_for_expr to be called on non-sra-candidate. From-SVN: r121578 --- gcc/ChangeLog | 6 ++++++ gcc/tree-sra.c | 9 ++++++--- 2 files changed, 12 insertions(+), 3 deletions(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 50aa8f191db..af87922453b 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,9 @@ +2007-02-04 Jan Hubicka + + * tree-sra.c (sra_walk_expr): Add linebreaks. BITFIELD_REFs into + vectors might cause maybe_lookup_element_for_expr to be called + on non-sra-candidate. + 2007-02-04 Kazu Hirata * config/bfin/bfin-modes.def, config/bfin/bfin.c, diff --git a/gcc/tree-sra.c b/gcc/tree-sra.c index a2d28cac2c4..03f9b59526a 100644 --- a/gcc/tree-sra.c +++ b/gcc/tree-sra.c @@ -793,10 +793,13 @@ sra_walk_expr (tree *expr_p, block_stmt_iterator *bsi, bool is_output, /* A bit field reference to a specific vector is scalarized but for ones for inputs need to be marked as used on the left hand size so when we scalarize it, we can mark that variable as non renamable. */ - if (is_output && TREE_CODE (TREE_TYPE (TREE_OPERAND (inner, 0))) == VECTOR_TYPE) + if (is_output + && TREE_CODE (TREE_TYPE (TREE_OPERAND (inner, 0))) == VECTOR_TYPE) { - struct sra_elt *elt = maybe_lookup_element_for_expr (TREE_OPERAND (inner, 0)); - elt->is_vector_lhs = true; + struct sra_elt *elt + = maybe_lookup_element_for_expr (TREE_OPERAND (inner, 0)); + if (elt) + elt->is_vector_lhs = true; } /* A bit field reference (access to *multiple* fields simultaneously) is not currently scalarized. Consider this an access to the -- 2.30.2