OSDN Git Service

2010-07-30 Richard Guenther <rguenther@suse.de>
authorrguenth <rguenth@138bc75d-0d04-0410-961f-82ee72b054a4>
Fri, 30 Jul 2010 11:01:22 +0000 (11:01 +0000)
committerrguenth <rguenth@138bc75d-0d04-0410-961f-82ee72b054a4>
Fri, 30 Jul 2010 11:01:22 +0000 (11:01 +0000)
PR middle-end/45141
* expr.c (expand_expr_real_1): Check for not handled base address.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@162709 138bc75d-0d04-0410-961f-82ee72b054a4

gcc/ChangeLog
gcc/expr.c

index 07da5fd..416d049 100644 (file)
@@ -1,5 +1,10 @@
 2010-07-30  Richard Guenther  <rguenther@suse.de>
 
+       PR middle-end/45141
+       * expr.c (expand_expr_real_1): Check for not handled base address.
+
+2010-07-30  Richard Guenther  <rguenther@suse.de>
+
        * ipa-prop.c (ipa_modify_formal_parameters): Use
        build_distinct_type_copy.
 
index a27dfd8..f0a3b9c 100644 (file)
@@ -8664,7 +8664,8 @@ expand_expr_real_1 (tree exp, rtx target, enum machine_mode tmode,
        set_mem_attributes (temp, TMR_ORIGINAL (exp), 0);
        set_mem_addr_space (temp, as);
        base = get_base_address (TMR_ORIGINAL (exp));
-       if (INDIRECT_REF_P (base)
+       if (base
+           && INDIRECT_REF_P (base)
            && TMR_BASE (exp)
            && TREE_CODE (TMR_BASE (exp)) == SSA_NAME
            && POINTER_TYPE_P (TREE_TYPE (TMR_BASE (exp))))