]> git.ipfire.org Git - thirdparty/gcc.git/commit
tree-optimization/107686 - fix bitfield ref through vec_unpack optimization
authorRichard Biener <rguenther@suse.de>
Wed, 16 Nov 2022 14:27:13 +0000 (15:27 +0100)
committerRichard Biener <rguenther@suse.de>
Mon, 12 Dec 2022 10:27:40 +0000 (11:27 +0100)
commit232305bd0c8dd37b17b815864e730aa630714606
treec22d013640152c0629c9bd118e2667a41d0c665c
parent9e242f8a2d5987ddaa74696e5ad809303ddc8dd0
tree-optimization/107686 - fix bitfield ref through vec_unpack optimization

The following propely restricts the bitfield access to integral types
when we look through VEC_UNPACK with the intent to emit a widening
conversion.

PR tree-optimization/107686
* tree-ssa-forwprop.cc (optimize_vector_load): Restrict
VEC_UNPACK support to integral typed bitfield refs.

* gcc.dg/pr107686.c: New testcase.

(cherry picked from commit 246bbdaa5f536b7a199dda9860c473137f40d622)
gcc/testsuite/gcc.dg/pr107686.c [new file with mode: 0644]
gcc/tree-ssa-forwprop.cc