From e7e9eb2f27fb3bc9b95de1881e5461c1133a25bc Mon Sep 17 00:00:00 2001 From: Nathan Froyd Date: Mon, 1 Nov 2010 18:58:30 +0000 Subject: re PR tree-optimization/46259 (Revision 166102 failed 416.gamess in SPEC CPU 2006) gcc/ 2010-11-01 Nathan Froyd PR tree-optimization/46259 Revert: 2010-10-30 Nathan Froyd * tree-vect-stmts.c (vect_get_vec_def_for_operand): Use build_vector_from_val. gcc/testsuite/ 2010-11-01 H.J. Lu Nathan Froyd PR tree-optimization/46259 * gfortran.dg/pr46259.f: New testcase. From-SVN: r166139 --- gcc/tree-vect-stmts.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'gcc/tree-vect-stmts.c') diff --git a/gcc/tree-vect-stmts.c b/gcc/tree-vect-stmts.c index 67e9e2b..183bb11 100644 --- a/gcc/tree-vect-stmts.c +++ b/gcc/tree-vect-stmts.c @@ -987,7 +987,9 @@ vect_get_vec_def_for_operand (tree op, gimple stmt, tree *scalar_def) loop_vec_info loop_vinfo = STMT_VINFO_LOOP_VINFO (stmt_vinfo); tree vec_inv; tree vec_cst; + tree t = NULL_TREE; tree def; + int i; enum vect_def_type dt; bool is_simple_use; tree vector_type; @@ -1049,7 +1051,13 @@ vect_get_vec_def_for_operand (tree op, gimple stmt, tree *scalar_def) if (vect_print_dump_info (REPORT_DETAILS)) fprintf (vect_dump, "Create vector_inv."); - vec_inv = build_vector_from_val (vector_type, def); + for (i = nunits - 1; i >= 0; --i) + { + t = tree_cons (NULL_TREE, def, t); + } + + /* FIXME: use build_constructor directly. */ + vec_inv = build_constructor_from_list (vector_type, t); return vect_init_vector (stmt, vec_inv, vector_type, NULL); } -- cgit v1.1