summaryrefslogtreecommitdiff
path: root/gcc/omp-low.c
diff options
context:
space:
mode:
authorrguenth <rguenth@138bc75d-0d04-0410-961f-82ee72b054a4>2009-04-15 16:12:01 +0000
committerrguenth <rguenth@138bc75d-0d04-0410-961f-82ee72b054a4>2009-04-15 16:12:01 +0000
commitc821ef7d3e4d8ed8ec600bf8f3e100a1168e2c47 (patch)
treedf6e6b24e71dfa49774871537c516ac031b4d427 /gcc/omp-low.c
parent841fdaa6384db60565fd3563c75fd45579dc2656 (diff)
downloadgcc-c821ef7d3e4d8ed8ec600bf8f3e100a1168e2c47.tar.gz
2009-04-15 Richard Guenther <rguenther@suse.de>
* omp-low.c (lower_rec_input_clauses): Build correct address expressions. (expand_omp_for_generic): Fix multiplication type. * tree-loop-distribution.c (build_size_arg): Build a size_t argument. (generate_memset_zero): Fix types. * tree-profile.c (prepare_instrumented_value): Correctly widen a pointer. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@146129 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/omp-low.c')
-rw-r--r--gcc/omp-low.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/gcc/omp-low.c b/gcc/omp-low.c
index be0153fea42..c28bbb0a1ca 100644
--- a/gcc/omp-low.c
+++ b/gcc/omp-low.c
@@ -2318,14 +2318,14 @@ lower_rec_input_clauses (tree clauses, gimple_seq *ilist, gimple_seq *dlist,
name);
gimple_add_tmp_var (x);
TREE_ADDRESSABLE (x) = 1;
- x = build_fold_addr_expr_with_type (x, TREE_TYPE (new_var));
+ x = build_fold_addr_expr (x);
}
else
{
x = build_call_expr (built_in_decls[BUILT_IN_ALLOCA], 1, x);
- x = fold_convert (TREE_TYPE (new_var), x);
}
+ x = fold_convert (TREE_TYPE (new_var), x);
gimplify_assign (new_var, x, ilist);
new_var = build_fold_indirect_ref (new_var);
@@ -3843,7 +3843,8 @@ expand_omp_for_generic (struct omp_region *region,
itype = lang_hooks.types.type_for_size (TYPE_PRECISION (vtype), 0);
t = fold_build2 (TRUNC_MOD_EXPR, type, tem, counts[i]);
t = fold_convert (itype, t);
- t = fold_build2 (MULT_EXPR, itype, t, fd->loops[i].step);
+ t = fold_build2 (MULT_EXPR, itype, t,
+ fold_convert (itype, fd->loops[i].step));
if (POINTER_TYPE_P (vtype))
t = fold_build2 (POINTER_PLUS_EXPR, vtype,
fd->loops[i].n1, fold_convert (sizetype, t));