summaryrefslogtreecommitdiff
path: root/gcc/tree-vect-data-refs.c
diff options
context:
space:
mode:
authorjakub <jakub@138bc75d-0d04-0410-961f-82ee72b054a4>2014-12-01 13:58:10 +0000
committerjakub <jakub@138bc75d-0d04-0410-961f-82ee72b054a4>2014-12-01 13:58:10 +0000
commite9cf809e2d07c8eadb9476fab56e5410133431a7 (patch)
treec094c055e477dd57b664cc7132206465d1b8cf55 /gcc/tree-vect-data-refs.c
parentc213d0dddaa542a1318d61a38907f4370f78c029 (diff)
downloadgcc-e9cf809e2d07c8eadb9476fab56e5410133431a7.tar.gz
* gimple.h (gimple_build_assign_stat): Remove prototype.
(gimple_build_assign): Remove define. Add overload prototypes with tree lhs and either a tree rhs, or enum tree_code and 1, 2 or 3 tree operands. * gimple.c (gimple_build_assign_stat): Renamed to... (gimple_build_assign): ... this. Add overloads with enum tree_code and 1, 2 or 3 tree operands. (gimple_build_assign_with_ops): Remove 1 and 2 operand overloads. Rename the 3 operand overload to ... (gimple_build_assign_1): ... this. Make it static inline. * tree-ssa-strlen.c (get_string_length): Use gimple_build_assign instead of gimple_build_assign_with_ops, swap the order of first two arguments and adjust formatting where necessary. * tree-vect-slp.c (vect_get_constant_vectors, vect_create_mask_and_perm): Likewise. * tree-ssa-forwprop.c (simplify_rotate): Likewise. * asan.c (build_shadow_mem_access, maybe_create_ssa_name, maybe_cast_to_ptrmode, asan_expand_check_ifn): Likewise. * tsan.c (instrument_builtin_call): Likewise. * tree-chkp.c (chkp_compute_bounds_for_assignment, chkp_generate_extern_var_bounds): Likewise. * tree-loop-distribution.c (generate_memset_builtin): Likewise. * tree-ssa-loop-im.c (rewrite_reciprocal): Likewise. * gimple-builder.c (build_assign, build_type_cast): Likewise. * tree-vect-loop-manip.c (vect_create_cond_for_align_checks): Likewise. * value-prof.c (gimple_divmod_fixed_value, gimple_mod_pow2, gimple_mod_subtract): Likewise. * gimple-match-head.c (maybe_push_res_to_seq): Likewise. * tree-vect-patterns.c (vect_recog_dot_prod_pattern, vect_recog_sad_pattern, vect_handle_widen_op_by_const, vect_recog_widen_mult_pattern, vect_recog_pow_pattern, vect_recog_widen_sum_pattern, vect_operation_fits_smaller_type, vect_recog_over_widening_pattern, vect_recog_widen_shift_pattern, vect_recog_rotate_pattern, vect_recog_vector_vector_shift_pattern, vect_recog_divmod_pattern, vect_recog_mixed_size_cond_pattern, adjust_bool_pattern_cast, adjust_bool_pattern, vect_recog_bool_pattern): Likewise. * gimple-ssa-strength-reduction.c (create_add_on_incoming_edge, insert_initializers, introduce_cast_before_cand, replace_one_candidate): Likewise. * tree-ssa-math-opts.c (insert_reciprocals, powi_as_mults_1, powi_as_mults, build_and_insert_binop, build_and_insert_cast, pass_cse_sincos::execute, bswap_replace, convert_mult_to_fma): Likewise. * tree-tailcall.c (adjust_return_value_with_ops, update_accumulator_with_ops): Likewise. * tree-predcom.c (reassociate_to_the_same_stmt): Likewise. * tree-ssa-reassoc.c (build_and_add_sum, optimize_range_tests_to_bit_test, update_ops, maybe_optimize_range_tests, rewrite_expr_tree, linearize_expr, negate_value, repropagate_negates, attempt_builtin_powi, reassociate_bb): Likewise. * tree-vect-loop.c (vect_is_simple_reduction_1, get_initial_def_for_induction, vect_create_epilog_for_reduction): Likewise. * ipa-split.c (split_function): Likewise. * tree-ssa-phiopt.c (conditional_replacement, minmax_replacement, abs_replacement, neg_replacement): Likewise. * tree-profile.c (gimple_gen_edge_profiler): Likewise. * tree-vrp.c (simplify_truth_ops_using_ranges, simplify_float_conversion_using_ranges, simplify_internal_call_using_ranges): Likewise. * gimple-fold.c (rewrite_to_defined_overflow, gimple_build): Likewise. * tree-vect-generic.c (expand_vector_divmod, optimize_vector_constructor): Likewise. * ubsan.c (ubsan_expand_null_ifn, ubsan_expand_objsize_ifn, instrument_bool_enum_load): Likewise. * tree-ssa-loop-manip.c (create_iv): Likewise. * omp-low.c (lower_rec_input_clauses, expand_omp_for_generic, expand_omp_for_static_nochunk, expand_omp_for_static_chunk, expand_cilk_for, simd_clone_adjust): Likewise. * trans-mem.c (expand_transaction): Likewise. * tree-vect-data-refs.c (bump_vector_ptr, vect_permute_store_chain, vect_setup_realignment, vect_permute_load_chain, vect_shift_permute_load_chain): Likewise. * tree-vect-stmts.c (vect_init_vector, vectorizable_mask_load_store, vectorizable_simd_clone_call, vect_gen_widened_results_half, vect_create_vectorized_demotion_stmts, vectorizable_conversion, vectorizable_shift, vectorizable_operation, vectorizable_store, permute_vec_elements, vectorizable_load): Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@218216 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/tree-vect-data-refs.c')
-rw-r--r--gcc/tree-vect-data-refs.c103
1 files changed, 46 insertions, 57 deletions
diff --git a/gcc/tree-vect-data-refs.c b/gcc/tree-vect-data-refs.c
index 4ed9bb14dc4..f7b192f966c 100644
--- a/gcc/tree-vect-data-refs.c
+++ b/gcc/tree-vect-data-refs.c
@@ -4348,8 +4348,8 @@ bump_vector_ptr (tree dataref_ptr, gimple ptr_incr, gimple_stmt_iterator *gsi,
update = bump;
new_dataref_ptr = copy_ssa_name (dataref_ptr);
- incr_stmt = gimple_build_assign_with_ops (POINTER_PLUS_EXPR, new_dataref_ptr,
- dataref_ptr, update);
+ incr_stmt = gimple_build_assign (new_dataref_ptr, POINTER_PLUS_EXPR,
+ dataref_ptr, update);
vect_finish_stmt_generation (stmt, incr_stmt, gsi);
/* Copy the points-to information if it exists. */
@@ -4640,9 +4640,8 @@ vect_permute_store_chain (vec<tree> dr_chain,
{j, nelt, *, j + 1, nelt + j + 1, *,
j + 2, nelt + j + 2, *, ...}> */
data_ref = make_temp_ssa_name (vectype, NULL, "vect_shuffle3_low");
- perm_stmt = gimple_build_assign_with_ops (VEC_PERM_EXPR, data_ref,
- vect1, vect2,
- perm3_mask_low);
+ perm_stmt = gimple_build_assign (data_ref, VEC_PERM_EXPR, vect1,
+ vect2, perm3_mask_low);
vect_finish_stmt_generation (stmt, perm_stmt, gsi);
vect1 = data_ref;
@@ -4652,9 +4651,8 @@ vect_permute_store_chain (vec<tree> dr_chain,
{0, 1, nelt + j, 3, 4, nelt + j + 1,
6, 7, nelt + j + 2, ...}> */
data_ref = make_temp_ssa_name (vectype, NULL, "vect_shuffle3_high");
- perm_stmt = gimple_build_assign_with_ops (VEC_PERM_EXPR, data_ref,
- vect1, vect2,
- perm3_mask_high);
+ perm_stmt = gimple_build_assign (data_ref, VEC_PERM_EXPR, vect1,
+ vect2, perm3_mask_high);
vect_finish_stmt_generation (stmt, perm_stmt, gsi);
(*result_chain)[j] = data_ref;
}
@@ -4686,9 +4684,8 @@ vect_permute_store_chain (vec<tree> dr_chain,
high = VEC_PERM_EXPR <vect1, vect2, {0, nelt, 1, nelt+1,
...}> */
high = make_temp_ssa_name (vectype, NULL, "vect_inter_high");
- perm_stmt
- = gimple_build_assign_with_ops (VEC_PERM_EXPR, high,
- vect1, vect2, perm_mask_high);
+ perm_stmt = gimple_build_assign (high, VEC_PERM_EXPR, vect1,
+ vect2, perm_mask_high);
vect_finish_stmt_generation (stmt, perm_stmt, gsi);
(*result_chain)[2*j] = high;
@@ -4697,9 +4694,8 @@ vect_permute_store_chain (vec<tree> dr_chain,
{nelt/2, nelt*3/2, nelt/2+1, nelt*3/2+1,
...}> */
low = make_temp_ssa_name (vectype, NULL, "vect_inter_low");
- perm_stmt
- = gimple_build_assign_with_ops (VEC_PERM_EXPR, low,
- vect1, vect2, perm_mask_low);
+ perm_stmt = gimple_build_assign (low, VEC_PERM_EXPR, vect1,
+ vect2, perm_mask_low);
vect_finish_stmt_generation (stmt, perm_stmt, gsi);
(*result_chain)[2*j+1] = low;
}
@@ -4880,8 +4876,8 @@ vect_setup_realignment (gimple stmt, gimple_stmt_iterator *gsi,
NULL_TREE, &init_addr, NULL, &inc,
true, &inv_p);
new_temp = copy_ssa_name (ptr);
- new_stmt = gimple_build_assign_with_ops
- (BIT_AND_EXPR, new_temp, ptr,
+ new_stmt = gimple_build_assign
+ (new_temp, BIT_AND_EXPR, ptr,
build_int_cst (TREE_TYPE (ptr),
-(HOST_WIDE_INT)TYPE_ALIGN_UNIT (vectype)));
new_bb = gsi_insert_on_edge_immediate (pe, new_stmt);
@@ -5194,9 +5190,8 @@ vect_permute_load_chain (vec<tree> dr_chain,
low = VEC_PERM_EXPR <first_vect, second_vect2, {k, 3 + k, 6 + k,
...}> */
data_ref = make_temp_ssa_name (vectype, NULL, "vect_shuffle3_low");
- perm_stmt = gimple_build_assign_with_ops (VEC_PERM_EXPR, data_ref,
- first_vect, second_vect,
- perm3_mask_low);
+ perm_stmt = gimple_build_assign (data_ref, VEC_PERM_EXPR, first_vect,
+ second_vect, perm3_mask_low);
vect_finish_stmt_generation (stmt, perm_stmt, gsi);
/* Create interleaving stmt (high part of):
@@ -5205,9 +5200,8 @@ vect_permute_load_chain (vec<tree> dr_chain,
first_vect = data_ref;
second_vect = dr_chain[2];
data_ref = make_temp_ssa_name (vectype, NULL, "vect_shuffle3_high");
- perm_stmt = gimple_build_assign_with_ops (VEC_PERM_EXPR, data_ref,
- first_vect, second_vect,
- perm3_mask_high);
+ perm_stmt = gimple_build_assign (data_ref, VEC_PERM_EXPR, first_vect,
+ second_vect, perm3_mask_high);
vect_finish_stmt_generation (stmt, perm_stmt, gsi);
(*result_chain)[k] = data_ref;
}
@@ -5234,17 +5228,17 @@ vect_permute_load_chain (vec<tree> dr_chain,
/* data_ref = permute_even (first_data_ref, second_data_ref); */
data_ref = make_temp_ssa_name (vectype, NULL, "vect_perm_even");
- perm_stmt = gimple_build_assign_with_ops (VEC_PERM_EXPR, data_ref,
- first_vect, second_vect,
- perm_mask_even);
+ perm_stmt = gimple_build_assign (data_ref, VEC_PERM_EXPR,
+ first_vect, second_vect,
+ perm_mask_even);
vect_finish_stmt_generation (stmt, perm_stmt, gsi);
(*result_chain)[j/2] = data_ref;
/* data_ref = permute_odd (first_data_ref, second_data_ref); */
data_ref = make_temp_ssa_name (vectype, NULL, "vect_perm_odd");
- perm_stmt = gimple_build_assign_with_ops (VEC_PERM_EXPR, data_ref,
- first_vect, second_vect,
- perm_mask_odd);
+ perm_stmt = gimple_build_assign (data_ref, VEC_PERM_EXPR,
+ first_vect, second_vect,
+ perm_mask_odd);
vect_finish_stmt_generation (stmt, perm_stmt, gsi);
(*result_chain)[j/2+length/2] = data_ref;
}
@@ -5431,30 +5425,28 @@ vect_shift_permute_load_chain (vec<tree> dr_chain,
second_vect = dr_chain[j + 1];
data_ref = make_temp_ssa_name (vectype, NULL, "vect_shuffle2");
- perm_stmt = gimple_build_assign_with_ops (VEC_PERM_EXPR, data_ref,
- first_vect, first_vect,
- perm2_mask1);
+ perm_stmt = gimple_build_assign (data_ref, VEC_PERM_EXPR,
+ first_vect, first_vect,
+ perm2_mask1);
vect_finish_stmt_generation (stmt, perm_stmt, gsi);
vect[0] = data_ref;
data_ref = make_temp_ssa_name (vectype, NULL, "vect_shuffle2");
- perm_stmt = gimple_build_assign_with_ops (VEC_PERM_EXPR, data_ref,
- second_vect, second_vect,
- perm2_mask2);
+ perm_stmt = gimple_build_assign (data_ref, VEC_PERM_EXPR,
+ second_vect, second_vect,
+ perm2_mask2);
vect_finish_stmt_generation (stmt, perm_stmt, gsi);
vect[1] = data_ref;
data_ref = make_temp_ssa_name (vectype, NULL, "vect_shift");
- perm_stmt = gimple_build_assign_with_ops (VEC_PERM_EXPR, data_ref,
- vect[0], vect[1],
- shift1_mask);
+ perm_stmt = gimple_build_assign (data_ref, VEC_PERM_EXPR,
+ vect[0], vect[1], shift1_mask);
vect_finish_stmt_generation (stmt, perm_stmt, gsi);
(*result_chain)[j/2 + length/2] = data_ref;
data_ref = make_temp_ssa_name (vectype, NULL, "vect_select");
- perm_stmt = gimple_build_assign_with_ops (VEC_PERM_EXPR, data_ref,
- vect[0], vect[1],
- select_mask);
+ perm_stmt = gimple_build_assign (data_ref, VEC_PERM_EXPR,
+ vect[0], vect[1], select_mask);
vect_finish_stmt_generation (stmt, perm_stmt, gsi);
(*result_chain)[j/2] = data_ref;
}
@@ -5544,9 +5536,9 @@ vect_shift_permute_load_chain (vec<tree> dr_chain,
for (k = 0; k < 3; k++)
{
data_ref = make_temp_ssa_name (vectype, NULL, "vect_shuffle3");
- perm_stmt = gimple_build_assign_with_ops (VEC_PERM_EXPR, data_ref,
- dr_chain[k], dr_chain[k],
- perm3_mask);
+ perm_stmt = gimple_build_assign (data_ref, VEC_PERM_EXPR,
+ dr_chain[k], dr_chain[k],
+ perm3_mask);
vect_finish_stmt_generation (stmt, perm_stmt, gsi);
vect[k] = data_ref;
}
@@ -5554,10 +5546,9 @@ vect_shift_permute_load_chain (vec<tree> dr_chain,
for (k = 0; k < 3; k++)
{
data_ref = make_temp_ssa_name (vectype, NULL, "vect_shift1");
- perm_stmt = gimple_build_assign_with_ops (VEC_PERM_EXPR, data_ref,
- vect[k % 3],
- vect[(k + 1) % 3],
- shift1_mask);
+ perm_stmt = gimple_build_assign (data_ref, VEC_PERM_EXPR,
+ vect[k % 3], vect[(k + 1) % 3],
+ shift1_mask);
vect_finish_stmt_generation (stmt, perm_stmt, gsi);
vect_shift[k] = data_ref;
}
@@ -5565,10 +5556,10 @@ vect_shift_permute_load_chain (vec<tree> dr_chain,
for (k = 0; k < 3; k++)
{
data_ref = make_temp_ssa_name (vectype, NULL, "vect_shift2");
- perm_stmt = gimple_build_assign_with_ops (VEC_PERM_EXPR, data_ref,
- vect_shift[(4 - k) % 3],
- vect_shift[(3 - k) % 3],
- shift2_mask);
+ perm_stmt = gimple_build_assign (data_ref, VEC_PERM_EXPR,
+ vect_shift[(4 - k) % 3],
+ vect_shift[(3 - k) % 3],
+ shift2_mask);
vect_finish_stmt_generation (stmt, perm_stmt, gsi);
vect[k] = data_ref;
}
@@ -5576,16 +5567,14 @@ vect_shift_permute_load_chain (vec<tree> dr_chain,
(*result_chain)[3 - (nelt % 3)] = vect[2];
data_ref = make_temp_ssa_name (vectype, NULL, "vect_shift3");
- perm_stmt = gimple_build_assign_with_ops (VEC_PERM_EXPR, data_ref,
- vect[0], vect[0],
- shift3_mask);
+ perm_stmt = gimple_build_assign (data_ref, VEC_PERM_EXPR, vect[0],
+ vect[0], shift3_mask);
vect_finish_stmt_generation (stmt, perm_stmt, gsi);
(*result_chain)[nelt % 3] = data_ref;
data_ref = make_temp_ssa_name (vectype, NULL, "vect_shift4");
- perm_stmt = gimple_build_assign_with_ops (VEC_PERM_EXPR, data_ref,
- vect[1], vect[1],
- shift4_mask);
+ perm_stmt = gimple_build_assign (data_ref, VEC_PERM_EXPR, vect[1],
+ vect[1], shift4_mask);
vect_finish_stmt_generation (stmt, perm_stmt, gsi);
(*result_chain)[0] = data_ref;
return true;