diff options
author | Jennifer Schmitz <jschmitz@nvidia.com> | 2024-10-03 04:46:51 -0700 |
---|---|---|
committer | Jennifer Schmitz <jschmitz@nvidia.com> | 2024-10-10 10:31:01 +0200 |
commit | a2e06b7f081a3d2e50e3afa8d3f1676a05099707 (patch) | |
tree | 59ffe18724ec525cb37dd113f2d4ef463c3ec6d3 /gcc/fortran/error.cc | |
parent | bcccc3221b838ee7ae7848e7194603acb18294b3 (diff) | |
download | gcc-a2e06b7f081a3d2e50e3afa8d3f1676a05099707.zip gcc-a2e06b7f081a3d2e50e3afa8d3f1676a05099707.tar.gz gcc-a2e06b7f081a3d2e50e3afa8d3f1676a05099707.tar.bz2 |
match.pd: Check trunc_mod vector obtap before folding.
This patch guards the simplification x / y * y == x -> x % y == 0 in
match.pd by a check for:
1) Non-vector mode of x OR
2) Lack of support for vector division OR
3) Support of vector modulo
The patch was bootstrapped and tested with no regression on
aarch64-linux-gnu and x86_64-linux-gnu.
OK for mainline?
Signed-off-by: Jennifer Schmitz <jschmitz@nvidia.com>
gcc/
PR tree-optimization/116831
* match.pd: Guard simplification to trunc_mod with check for
mod optab support.
gcc/testsuite/
PR tree-optimization/116831
* gcc.dg/torture/pr116831.c: New test.
Diffstat (limited to 'gcc/fortran/error.cc')
0 files changed, 0 insertions, 0 deletions