aboutsummaryrefslogtreecommitdiff
path: root/gcc/expr.c
diff options
context:
space:
mode:
authorJakub Jelinek <jakub@redhat.com>2012-10-02 13:43:09 +0000
committerJakub Jelinek <jakub@redhat.com>2012-10-02 13:43:09 +0000
commit47f1118ad5e5f48d696eccf2c923f36631892e5a (patch)
tree3adb3336c25f30bb07febeff1971bf93fbfcc921 /gcc/expr.c
parentc8364101170a507c9dc7e6bbe1d4e83442b9a939 (diff)
PR tree-optimization/54713
* expr.c (categorize_ctor_elements_1): Don't assume purpose is non-NULL. * tree-cfg.c (verify_gimple_assign_single): Add verification of vector CONSTRUCTORs. * tree-ssa-sccvn.c (vn_reference_lookup_3): For VECTOR_TYPE CONSTRUCTORs, don't do anything if element type is VECTOR_TYPE, and don't check index. * tree-vect-slp.c (vect_get_constant_vectors): VIEW_CONVERT_EXPR ctor elements first if their type isn't compatible with vector element type. git-svn-id: https://gcc.gnu.org/svn/gcc/trunk@191983 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/expr.c')
-rw-r--r--gcc/expr.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/gcc/expr.c b/gcc/expr.c
index c180e8d5edc..1adea93c316 100644
--- a/gcc/expr.c
+++ b/gcc/expr.c
@@ -5491,7 +5491,7 @@ categorize_ctor_elements_1 (const_tree ctor, HOST_WIDE_INT *p_nz_elts,
{
HOST_WIDE_INT mult = 1;
- if (TREE_CODE (purpose) == RANGE_EXPR)
+ if (purpose && TREE_CODE (purpose) == RANGE_EXPR)
{
tree lo_index = TREE_OPERAND (purpose, 0);
tree hi_index = TREE_OPERAND (purpose, 1);