https://gcc.gnu.org/bugzilla/show_bug.cgi?id=128970
--- Comment #2 from Dmitry Babokin <babokin at gmail dot com> ---
Interesting variation - it fails only with address sanitizer enabled:
root@fb51b0fe95ef:/opt/yarpgen# cat "$R/seed402143466.cpp"
struct S { int b : 6; } s{0};
unsigned long long p = 1;
int get() { return 1; }
int f() { return ((get() ? s.b : s.b) > 0) * (1 % (p | 1)) * 0; }
int main() { return f(); }
root@fb51b0fe95ef:/opt/yarpgen# /opt/gcc/bin/g++ -std=c++17 -O0
-fsanitize=undefined,address "$R/seed402143466.cpp" -o /tmp/repro
results/bootstrap-8h-verified/minimal-reproducers/seed402143466.cpp: In
function 'int f()':
results/bootstrap-8h-verified/minimal-reproducers/seed402143466.cpp:4:5: error:
mismatching comparison operand types
4 | int f() { return ((get() ? s.b : s.b) > 0) * (1 % (p | 1)) * 0; }
| ^
<unnamed-signed:6>
int
_3 = _2 > 0;
results/bootstrap-8h-verified/minimal-reproducers/seed402143466.cpp:4:5:
internal compiler error: 'verify_gimple' failed
0x2ca53d3 internal_error(char const*, ...)
/tmp/src/gcc/gcc/diagnostic-global-context.cc:787
0x15f049b verify_gimple_in_seq(gimple*, bool)
/tmp/src/gcc/gcc/tree-cfg.cc:5304
0x121c0e3 gimplify_body(tree_node*, bool)
/tmp/src/gcc/gcc/gimplify.cc:21937
0x121c41b gimplify_function_tree(tree_node*)
/tmp/src/gcc/gcc/gimplify.cc:22063
0xf8bea3 cgraph_node::analyze()
/tmp/src/gcc/gcc/cgraphunit.cc:695
0xf8ed6f analyze_functions
/tmp/src/gcc/gcc/cgraphunit.cc:1271
0xf900f7 symbol_table::finalize_compilation_unit()
/tmp/src/gcc/gcc/cgraphunit.cc:2594
/opt/gcc/libexec/gcc/aarch64-unknown-linux-gnu/17.0.0/cc1plus -quiet
-imultiarch aarch64-linux-gnu -D_GNU_SOURCE
results/bootstrap-8h-verified/minimal-reproducers/seed402143466.cpp
-funwind-tables -quiet -dumpdir /tmp/repro- -dumpbase seed402143466.cpp
-dumpbase-ext .cpp -mlittle-endian -mabi=lp64 -O0 -std=c++17
-fsanitize=undefined,address -o /tmp/ccS7DWe8.s
Please submit a full bug report, with preprocessed source (by using
-freport-bug).
Please include the complete backtrace with any bug report.
See <https://gcc.gnu.org/bugs/> for instructions.
root@fb51b0fe95ef:/opt/yarpgen# /opt/gcc/bin/g++ -std=c++17 -O0
"$R/seed402143466.cpp" -o /tmp/repro