Debian Codegraph @

gcc/testsuite/gcc.target/loongarch/jump-table-annotate.c

raw
1 /* { dg-do compile } */
2 /* { dg-additional-options "-O -mannotate-tablejump" } */
3
4 extern void asdf(int);
5 void foo(int x) {
6 switch (x) {
7 case 0: asdf(10); break;
8 case 1: asdf(11); break;
9 case 2: asdf(12); break;
10 case 3: asdf(13); break;
11 case 4: asdf(14); break;
12 }
13 }
14
15 /* { dg-final { scan-assembler "\\.discard\\.tablejump_annotate" } } */