diff options
author | rguenth <rguenth@138bc75d-0d04-0410-961f-82ee72b054a4> | 2016-04-20 12:49:58 +0000 |
---|---|---|
committer | rguenth <rguenth@138bc75d-0d04-0410-961f-82ee72b054a4> | 2016-04-20 12:49:58 +0000 |
commit | eadb4d2f91e15d75cec8dfb9447ce63a0c5821e8 (patch) | |
tree | 6ecda2e36f59655af88a3d7c0521fb193010349e /gcc/gimple-match-head.c | |
parent | a8876617811b8999e71d100cdd682b4e76c04b67 (diff) | |
download | gcc-eadb4d2f91e15d75cec8dfb9447ce63a0c5821e8.tar.gz |
2016-04-20 Richard Biener <rguenther@suse.de>
* gimple-match.h (maybe_build_generic_op): Adjust prototype.
* gimple-match-head.c (maybe_build_generic_op): Pass all ops
by reference, clear op1 and op2 when GENERICizing BIT_FIELD_REF.
(maybe_push_res_to_seq): Adjust.
* gimple-fold.c (maybe_build_generic_op): Likewise.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@235274 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/gimple-match-head.c')
-rw-r--r-- | gcc/gimple-match-head.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/gcc/gimple-match-head.c b/gcc/gimple-match-head.c index c86a4ffb0e3..2beadbc2905 100644 --- a/gcc/gimple-match-head.c +++ b/gcc/gimple-match-head.c @@ -233,18 +233,18 @@ gimple_resimplify3 (gimple_seq *seq, a GENERIC tree for that expression into *OP0. */ void -maybe_build_generic_op (enum tree_code code, tree type, - tree *op0, tree op1, tree op2) +maybe_build_generic_op (enum tree_code code, tree type, tree *ops) { switch (code) { case REALPART_EXPR: case IMAGPART_EXPR: case VIEW_CONVERT_EXPR: - *op0 = build1 (code, type, *op0); + ops[0] = build1 (code, type, ops[0]); break; case BIT_FIELD_REF: - *op0 = build3 (code, type, *op0, op1, op2); + ops[0] = build3 (code, type, ops[0], ops[1], ops[2]); + ops[1] = ops[2] = NULL_TREE; break; default:; } @@ -316,7 +316,7 @@ maybe_push_res_to_seq (code_helper rcode, tree type, tree *ops, else res = create_tmp_reg (type); } - maybe_build_generic_op (rcode, type, &ops[0], ops[1], ops[2]); + maybe_build_generic_op (rcode, type, ops); gimple *new_stmt = gimple_build_assign (res, rcode, ops[0], ops[1], ops[2]); gimple_seq_add_stmt_without_update (seq, new_stmt); |