PR107920: Fix handling of virtual operands and disable folding for -fnon-call-exceptions.
authorPrathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
Wed, 7 Dec 2022 08:04:02 +0000 (13:34 +0530)
committerPrathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
Wed, 7 Dec 2022 08:04:18 +0000 (13:34 +0530)
commitcb6922f490d3133e4ccbc1190b555d16695fc9c3
tree7279983f3314ccab9af37b4b93e0088dd75a03e0
parentda7fb32d403759daefefc79dc251d2437c1b638c
PR107920: Fix handling of virtual operands and disable folding for -fnon-call-exceptions.

gcc/ChangeLog:
PR target/107920
* config/aarch64/aarch64-sve-builtins-base.cc: Use
gsi_replace_with_seq_vops to handle virtual operands, and gate
the transform on !flag_non_call_exceptions.
* gimple-fold.cc (gsi_replace_with_seq_vops): Make function non static.
* gimple-fold.h (gsi_replace_with_seq_vops): Declare.

gcc/testsuite/ChangeLog:
PR target/107920
* gcc.target/aarch64/sve/acle/general/pr107920.c: New test.
* g++.target/aarch64/sve/pr107920.C: Likewise.
gcc/config/aarch64/aarch64-sve-builtins-base.cc
gcc/gimple-fold.cc
gcc/gimple-fold.h
gcc/testsuite/g++.target/aarch64/sve/pr107920.C [new file with mode: 0644]
gcc/testsuite/gcc.target/aarch64/sve/acle/general/pr107920.c [new file with mode: 0644]