Hi, This is a V2 of https://gcc.gnu.org/pipermail/gcc-patches/2025-May/683650.html.
Apologies for the delay - I was hesistant to push without preserving sve/pr96357.c and regtesting x86. The change to sve/pr96357.c means that it can still be vectorized, and will still trigger the ICE without Przemek's fix applied. I'd like to be able to test this change for VEC_UNPACK_FIX_TRUNC_HI_EXPR, VEC_UNPACK_FIX_TRUNC_LO_EXPR and VEC_PACK_FIX_TRUNC_EXP - but I've struggled to come up with a practical way to do that... Bootstrapped & regtested on aarch64-linux-gnu, x86_64-linux-gnu. OK for master? Thanks, Spencer Spencer Abson (1): middle-end: Fix operation_could_trap_p for FIX_TRUNC expressions .../gcc.dg/tree-ssa/ifcvt-fix-trunc-1.c | 19 +++++++++++++++++++ .../gcc.dg/tree-ssa/ifcvt-fix-trunc-2.c | 6 ++++++ .../gcc.target/aarch64/sve/pr96357.c | 8 ++++---- gcc/tree-eh.cc | 7 +++++++ 4 files changed, 36 insertions(+), 4 deletions(-) create mode 100644 gcc/testsuite/gcc.dg/tree-ssa/ifcvt-fix-trunc-1.c create mode 100644 gcc/testsuite/gcc.dg/tree-ssa/ifcvt-fix-trunc-2.c -- 2.34.1