[Bug tree-optimization/107997] [10/11/12/13 Regression] r13-4389-gfd8dd6c0384969 probably uncovered an issue building the Linux kernel
cvs-commit at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Mon Mar 16 13:38:36 GMT 2026
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107997
--- Comment #21 from GCC Commits <cvs-commit at gcc dot gnu.org> ---
The releases/gcc-14 branch has been updated by Richard Biener
<rguenth@gcc.gnu.org>:
https://gcc.gnu.org/g:cf074920bec5acafb4a1783bfe4121b8b869938d
commit r14-12439-gcf074920bec5acafb4a1783bfe4121b8b869938d
Author: Richard Biener <rguenther@suse.de>
Date: Mon Sep 8 14:32:38 2025 +0200
tree-optimization/121844 - IVOPTs and asm goto in latch
When there's an asm goto in the latch of a loop we may not use
IP_END IVs since instantiating those would (need to) split the
latch edge which in turn invalidates IP_NORMAL position handling.
This is a revision of the PR107997 fix.
PR tree-optimization/107997
PR tree-optimization/121844
* tree-ssa-loop-ivopts.cc (allow_ip_end_pos_p): Do not allow
IP_END for latches ending with a control stmt.
(create_new_iv): Do not split the latch edge, instead assert
that's not necessary.
* gcc.dg/torture/pr121844.c: New testcase.
(cherry picked from commit 00cd34b1046076a3272f8e8e85c97dc8f4d2ea44)
More information about the Gcc-bugs
mailing list