]> git.ipfire.org Git - thirdparty/gcc.git/commit
tree-optimization/113431 - wrong dependence with invariant load
authorRichard Biener <rguenther@suse.de>
Wed, 17 Jan 2024 13:05:42 +0000 (14:05 +0100)
committerRichard Biener <rguenther@suse.de>
Thu, 18 Jan 2024 07:31:41 +0000 (08:31 +0100)
commitb981d5c60b8ef78e2adecd6b5d7e36f9e5e61c54
tree0370227d5c2ce54cf95261ab2592d6fd8a54290a
parent0f38666680d6ad0e40c4a8b6d94b2c93931cdf42
tree-optimization/113431 - wrong dependence with invariant load

The vectorizer dependence analysis is confused with invariant loads
when figuring whether the circumstances are so that we preserve
scalar stmt execution order.  The following rectifies this.

PR tree-optimization/113431
* tree-vect-data-refs.cc (vect_preserves_scalar_order_p):
When there is an invariant load we might not preserve
scalar order.

* gcc.dg/vect/pr113431.c: New testcase.
gcc/testsuite/gcc.dg/vect/pr113431.c [new file with mode: 0644]
gcc/tree-vect-data-refs.cc