annotate gcc/testsuite/gcc.dg/alias-10.c @ 145:1830386684a0

gcc-9.2.0
author anatofuz
date Thu, 13 Feb 2020 11:34:05 +0900
parents 04ced10e8804
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
111
kono
parents:
diff changeset
1 /* For PR tree-optimization/14784 */
kono
parents:
diff changeset
2
kono
parents:
diff changeset
3 /* { dg-do compile } */
kono
parents:
diff changeset
4 /* { dg-options "-O2 -funswitch-loops -fdump-tree-unswitch-details" } */
kono
parents:
diff changeset
5
kono
parents:
diff changeset
6 typedef struct bitmap_element_def
kono
parents:
diff changeset
7 {
kono
parents:
diff changeset
8 unsigned int indx;
kono
parents:
diff changeset
9 } bitmap_element;
kono
parents:
diff changeset
10
kono
parents:
diff changeset
11 typedef struct bitmap_head_def {
kono
parents:
diff changeset
12 bitmap_element *first;
kono
parents:
diff changeset
13 int using_obstack;
kono
parents:
diff changeset
14 } bitmap_head;
kono
parents:
diff changeset
15 typedef struct bitmap_head_def *bitmap;
kono
parents:
diff changeset
16
kono
parents:
diff changeset
17 bitmap_element *bitmap_free;
kono
parents:
diff changeset
18
kono
parents:
diff changeset
19 void foo (bitmap head, bitmap_element *elt)
kono
parents:
diff changeset
20 {
kono
parents:
diff changeset
21 while (1)
kono
parents:
diff changeset
22 {
kono
parents:
diff changeset
23 /* Alias analysis problems used to prevent us from recognizing
kono
parents:
diff changeset
24 that this condition is invariant. */
kono
parents:
diff changeset
25 if (head->using_obstack)
kono
parents:
diff changeset
26 bitmap_free = elt;
kono
parents:
diff changeset
27 }
kono
parents:
diff changeset
28 }
kono
parents:
diff changeset
29
kono
parents:
diff changeset
30
kono
parents:
diff changeset
31 /* { dg-final { scan-tree-dump-times "Unswitching" 1 "unswitch"} } */