* gcc.dg/torture/stackalign/builtin-apply-2.c: Fix skip-if syntax.
[official-gcc.git] / gcc / testsuite / gcc.dg / asan / use-after-scope-switch-3.c
blobf361591351b7ed16e913368c31b631cd58ee9731
1 // { dg-do run }
2 // { dg-additional-options "-fdump-tree-gimple" }
4 int
5 main (int argc, char **argv)
7 int *ptr = 0;
9 for (unsigned i = 0; i < 2; i++)
11 switch (argc)
13 case 11111:;
14 int a;
15 ptr = &a;
16 break;
18 default:
19 ptr = &a;
20 *ptr = 12345;
21 case 222222:
22 my_label:
23 ptr = &a;
24 break;
29 if (argc == 333333)
30 goto my_label;
32 return 0;
35 /* { dg-final { scan-tree-dump-times "ASAN_MARK \\(UNPOISON, &a, \[0-9\]\\);" 4 "gimple" } } */
36 /* { dg-final { scan-tree-dump-times "ASAN_MARK \\(POISON, &a, \[0-9\]\\);" 1 "gimple" } } */