aboutsummaryrefslogtreecommitdiff
path: root/gcc/fortran/parse.cc
diff options
context:
space:
mode:
authorJakub Jelinek <jakub@redhat.com>2022-12-13 16:55:21 +0100
committerJakub Jelinek <jakub@redhat.com>2022-12-13 16:55:21 +0100
commit33be3ee36a7e2c0be383ec01b5fbc9aef39568fd (patch)
tree54a51e8ca48643355721638e9971b8dc3c4f79ef /gcc/fortran/parse.cc
parent8f4634fb82d5670183d0ee42de9dae3b55ab5087 (diff)
downloadgcc-33be3ee36a7e2c0be383ec01b5fbc9aef39568fd.zip
gcc-33be3ee36a7e2c0be383ec01b5fbc9aef39568fd.tar.gz
gcc-33be3ee36a7e2c0be383ec01b5fbc9aef39568fd.tar.bz2
vect-patterns: Fix up vect_recog_rotate_pattern [PR108064]
Since vect_recog_rotate_pattern has been extended to work also on signed types in r13-1100 we miscompile the testcase below. vect_recog_rotate_pattern actually emits correct scalar code into the pattern def sequence (in particular cast to utype, doing the 2 shifts in utype so that the right shift is logical and not arithmetic, or and then cast back to the signed type), but it didn't supply vectype for most of those pattern statements, which means that the generic handling fills it up later with the vectype provided by vect_recog_rotate_pattern. The problem is that it is vectype of the result of the whole pattern, i.e. vector of signed values in this case, while the conversion to utype, 2 shifts and or (everything with utype lhs in scalar code) should have uvectype as STMT_VINFO_VECTYPE. 2022-12-13 Jakub Jelinek <jakub@redhat.com> PR tree-optimization/108064 * tree-vect-patterns.cc (vect_recog_rotate_pattern): Pass uvectype as 4th argument to append_pattern_def_seq for statements with lhs with utype type. * gcc.c-torture/execute/pr108064.c: New test.
Diffstat (limited to 'gcc/fortran/parse.cc')
0 files changed, 0 insertions, 0 deletions