https://gcc.gnu.org/bugzilla/show_bug.cgi?id=125870
Bug ID: 125870
Summary: ICE in fill_block_cache, at gimple-range-cache.cc:1608
Product: gcc
Version: 17.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: middle-end
Assignee: unassigned at gcc dot gnu.org
Reporter: kargl at gcc dot gnu.org
Target Milestone: ---
When bootstrapping on x86_64-*-freebsd, with gfortran support, I'm seeing
the following ICE. I cannot tell if the informative note is related or
not.
../../../gcc/libgfortran/io/write.c: In function 'write_ex':
../../../gcc/libgfortran/io/write.c:2093:17: warning: '%0*d' directive output
may be truncated writing between 1 and 2147483647 bytes into a region of size
62 [-Wformat-truncation=]
2093 | "P%c%0*d", sign_char, exp_digits, abs (exp_value));
| ^~~~
../../../gcc/libgfortran/io/write.c:2093:13: note: directive argument in the
range [0, 2147483647]
2093 | "P%c%0*d", sign_char, exp_digits, abs (exp_value));
| ^~~~~~~~~
../../../gcc/libgfortran/io/write.c:2092:3: note: 'snprintf' output between 4
and 2147483650 bytes into a destination of size 64
2092 | snprintf (output + mantissa_len, sizeof (output) - mantissa_len,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2093 | "P%c%0*d", sign_char, exp_digits, abs (exp_value));
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
during RTL pass: expand
../../../gcc/libgfortran/io/write.c:2022:15: internal compiler error: in
fill_block_cache, at gimple-range-cache.cc:1608
2022 | memmove (decimal + d + 1, p_pos, strlen (p_pos) + 1);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
0x279f97b internal_error(char const*, ...)
../../gcc/gcc/diagnostic-global-context.cc:787
0x9f43f4 fancy_abort(char const*, int, char const*)
../../gcc/gcc/diagnostics/context.cc:1813
0x7ee2f3 ranger_cache::fill_block_cache(tree_node*, basic_block_def*,
basic_block_def*)