https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70944

            Bug ID: 70944
           Summary: [7 Regression] ICE in immed_wide_int_const, at
                    emit-rtl.c:606 with -O3
           Product: gcc
           Version: 7.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: tree-optimization
          Assignee: unassigned at gcc dot gnu.org
          Reporter: marxin at gcc dot gnu.org
  Target Milestone: ---

As mentioned in https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70396#c5,
after Richi's fix for PR70396, I still see very similar issue.

$ cat tc.ii

void fn1() {
  unsigned *a = 0;
  for (int i; i; ++i) {
    unsigned g(a[i] << 8 >> 24);
    a[i] = g;
  }
}

$ /home/marxin/bin/gcc2/lib/gcc/x86_64-pc-linux-gnu/7.0.0/cc1plus
-fpreprocessed tc.ii -march=haswell -mmmx -mno-3dnow -msse -msse2 -msse3
-mssse3 -mno-sse4a -mcx16 -msahf -mmovbe -maes -mno-sha -mpclmul -mpopcnt -mabm
-mno-lwp -mfma -mno-fma4 -mno-xop -mbmi -mbmi2 -mno-tbm -mavx -mavx2 -msse4.2
-msse4.1 -mlzcnt -mno-rtm -mno-hle -mrdrnd -mf16c -mfsgsbase -mno-rdseed
-mno-prfchw -mno-adx -mfxsr -mxsave -mxsaveopt -mno-avx512f -mno-avx512er
-mno-avx512cd -mno-avx512pf -mno-prefetchwt1 -mno-clflushopt -mno-xsavec
-mno-xsaves -mno-avx512dq -mno-avx512bw -mno-avx512vl -mno-avx512ifma
-mno-avx512vbmi -mno-clwb -mno-pcommit -mno-mwaitx -mno-clzero -mno-pku --param
l1-cache-size=32 --param l1-cache-line-size=64 --param l2-cache-size=8192
-mtune=haswell -quiet -dumpbase tc.ii -O3

tc.ii:7:1: internal compiler error: in immed_wide_int_const, at emit-rtl.c:606
 }
 ^
0xa4cf35 immed_wide_int_const(generic_wide_int<wide_int_ref_storage<false> >
const&, machine_mode)
        ../../gcc/emit-rtl.c:606
0x13929a9 change_zero_ext
        ../../gcc/combine.c:11111
0x13937d8 recog_for_combine
        ../../gcc/combine.c:11148
0x13a175d try_combine
        ../../gcc/combine.c:3503
0x13a6fc1 combine_instructions
        ../../gcc/combine.c:1288
0x13a6fc1 rest_of_handle_combine
        ../../gcc/combine.c:14348
0x13a6fc1 execute
        ../../gcc/combine.c:14391

Thanks

Reply via email to