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

            Bug ID: 99328
           Summary: ICE: in verify_target_availability, at
                    sel-sched.c:1557 with -fselective-scheduling2 on
                    aarch64
           Product: gcc
           Version: 11.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: rtl-optimization
          Assignee: unassigned at gcc dot gnu.org
          Reporter: qinzhao at gcc dot gnu.org
  Target Milestone: ---

gcc11 has the following ICE:

$ cat t.c
long a;
double b, c;
double fn1(double);
void fn2(long *);
void fn3(int p1) {
  fn2(&a);
  if (fn1(0) >= p1)
    b = c;
}

$ sh t
/data1/qing/Install/latest/bin/gcc -fprofile-generate -Ofast
-fselective-scheduling -fselective-scheduling2 -c -o t.o t.c
during RTL pass: sched2
t.c: In function 'fn3':
t.c:9:1: internal compiler error: in verify_target_availability, at
sel-sched.c:1557
    9 | }
      | ^
0xd86fbb verify_target_availability
        ../../latest_gcc/gcc/sel-sched.c:1553
0xd86fbb find_best_reg_for_expr
        ../../latest_gcc/gcc/sel-sched.c:1667
0xd89f33 fill_vec_av_set
        ../../latest_gcc/gcc/sel-sched.c:3784
0xd89f33 fill_ready_list
        ../../latest_gcc/gcc/sel-sched.c:4014
0xd89f33 find_best_expr
        ../../latest_gcc/gcc/sel-sched.c:4374
0xd89f33 fill_insns
        ../../latest_gcc/gcc/sel-sched.c:5535
0xd8ba17 schedule_on_fences
        ../../latest_gcc/gcc/sel-sched.c:7353
0xd8ba17 sel_sched_region_2
        ../../latest_gcc/gcc/sel-sched.c:7491
0xd8c517 sel_sched_region_1
        ../../latest_gcc/gcc/sel-sched.c:7533
0xd8e573 sel_sched_region(int)
        ../../latest_gcc/gcc/sel-sched.c:7634
0xd8f1b7 run_selective_scheduling()
        ../../latest_gcc/gcc/sel-sched.c:7720
0xd6a32f rest_of_handle_sched2
        ../../latest_gcc/gcc/sched-rgn.c:3738
0xd6a32f execute
        ../../latest_gcc/gcc/sched-rgn.c:3882
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.

this is a reduced testing case from CPU2017 511.povray.
gcc10 has the same issue.

Reply via email to