https://gcc.gnu.org/bugzilla/show_bug.cgi?id=118819
--- Comment #7 from GCC Commits <cvs-commit at gcc dot gnu.org> --- The master branch has been updated by Jakub Jelinek <ja...@gcc.gnu.org>: https://gcc.gnu.org/g:b570f48c3dfb9ca3d640467cff67e569904009d4 commit r15-7722-gb570f48c3dfb9ca3d640467cff67e569904009d4 Author: Jakub Jelinek <ja...@redhat.com> Date: Thu Feb 27 08:48:18 2025 +0100 alias: Perform offset arithmetics in poly_offset_int rather than poly_int64 [PR118819] This PR is about ubsan error on the c - cx1 + cy1 evaluation in the first hunk. The following patch hopefully fixes that by doing the additions/subtractions in poly_offset_int rather than poly_int64 and then converting back to poly_int64. If it doesn't fit, -1 is returned (which means it is unknown if there is a conflict or not). 2025-02-27 Jakub Jelinek <ja...@redhat.com> PR middle-end/118819 * alias.cc (memrefs_conflict_p): Perform arithmetics on c, xsize and ysize in poly_offset_int and return -1 if it is not representable in poly_int64.