diff options
author | H.J. Lu <hjl.tools@gmail.com> | 2012-04-03 10:55:16 -0700 |
---|---|---|
committer | H.J. Lu <hjl.tools@gmail.com> | 2012-04-03 10:55:16 -0700 |
commit | 6a14926b44504e88488e3715b5b84928d454fb49 (patch) | |
tree | 9cf5f80773922c62ebd9ba07388a1f27354dc516 /gcc/tree-vect-slp.c | |
parent | aabd700dee5d71eb0a8180fb3626a23da9a88fdd (diff) | |
parent | 749dea2a0549c126a0e992a6dd8e9b5eb28e1cee (diff) | |
download | gcc-hjl/x32/java.tar.gz |
Merge remote-tracking branch 'origin/master' into hjl/x32/javahjl/x32/java
Diffstat (limited to 'gcc/tree-vect-slp.c')
-rw-r--r-- | gcc/tree-vect-slp.c | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/gcc/tree-vect-slp.c b/gcc/tree-vect-slp.c index c142bbb0201..0ab6be0671a 100644 --- a/gcc/tree-vect-slp.c +++ b/gcc/tree-vect-slp.c @@ -2337,8 +2337,23 @@ vect_get_constant_vectors (tree op, slp_tree slp_node, op = gimple_call_arg (stmt, op_num); break; + case LSHIFT_EXPR: + case RSHIFT_EXPR: + case LROTATE_EXPR: + case RROTATE_EXPR: + op = gimple_op (stmt, op_num + 1); + /* Unlike the other binary operators, shifts/rotates have + the shift count being int, instead of the same type as + the lhs, so make sure the scalar is the right type if + we are dealing with vectors of + long long/long/short/char. */ + if (op_num == 1 && constant_p) + op = fold_convert (TREE_TYPE (vector_type), op); + break; + default: op = gimple_op (stmt, op_num + 1); + break; } } |