https://gcc.gnu.org/bugzilla/show_bug.cgi?id=82816
Bug ID: 82816 Summary: ICE on valid code at -Os and above: in find_widening_optab_handler_and_mode, at optabs-query.c:414 Product: gcc Version: unknown Status: UNCONFIRMED Severity: normal Priority: P3 Component: tree-optimization Assignee: unassigned at gcc dot gnu.org Reporter: su at cs dot ucdavis.edu Target Milestone: --- This appears to be a recent regression. $ gcctk -v Using built-in specs. COLLECT_GCC=gcctk COLLECT_LTO_WRAPPER=/home/su/software/tmp/gcc/gcc-trunk/libexec/gcc/x86_64-pc-linux-gnu/8.0.0/lto-wrapper Target: x86_64-pc-linux-gnu Configured with: ../gcc-source-trunk/configure --enable-languages=c,c++,lto --prefix=/home/su/software/tmp/gcc/gcc-trunk --disable-bootstrap Thread model: posix gcc version 8.0.0 20171102 (experimental) [trunk revision 254338] (GCC) $ $ gcctk -O1 -c small.c $ gcc-7.2.0 -Os -c small.c $ $ gcctk -Os -c small.c during GIMPLE pass: widening_mul small.c: In function âfâ: small.c:8:6: internal compiler error: in find_widening_optab_handler_and_mode, at optabs-query.c:414 void f () ^ 0xb749b8 find_widening_optab_handler_and_mode(optab_tag, machine_mode, machine_mode, machine_mode*) ../../gcc-source-trunk/gcc/optabs-query.c:414 0xe0b484 insn_code find_widening_optab_handler_and_mode<scalar_int_mode>(optab_tag, scalar_int_mode const&, scalar_int_mode const&, scalar_int_mode*) ../../gcc-source-trunk/gcc/optabs-query.h:201 0xe0b484 convert_mult_to_widen ../../gcc-source-trunk/gcc/tree-ssa-math-opts.c:3273 0xe0f29f execute ../../gcc-source-trunk/gcc/tree-ssa-math-opts.c:4205 Please submit a full bug report, with preprocessed source if appropriate. Please include the complete backtrace with any bug report. See <https://gcc.gnu.org/bugs/> for instructions. $ ------------------------------ struct A { int b:3; } d, e; int c; void f () { char g = d.b * e.b; c = g; }