toolchain: gcc: backport patch to fix ICE with PowerPC targets
During the build of perl, the following ICE was reported in
https://github.com/openwrt/packages/issues/24565 when targeting PowerPC:
during RTL pass: reload
blocksort.c: In function 'mainSort.isra':
blocksort.c:1011:1: internal compiler error: in patch_jump_insn, at cfgrtl.cc:1303
1011 | }
| ^
0x7d49cee29d8f __libc_start_call_main
../sysdeps/nptl/libc_start_call_main.h:58
0x7d49cee29e3f __libc_start_main_impl
../csu/libc-start.c:392
Please submit a full bug report, with preprocessed source (by using -freport-bug).
Please include the complete backtrace with any bug report.
See <http://bugs.openwrt.org/> for instructions.
The same issue also caused the CI failures in
https://github.com/openwrt/packages/pull/26501.
The issue only occurs with GCC 14.2.0, but not with the head of the
releases/gcc-14 maintenance branch; a bisect found that this patch fixes
it.
Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
Link: https://github.com/openwrt/openwrt/pull/18797
Signed-off-by: Robert Marko <robimarko@gmail.com>