Adjust scan string for PIE
[official-gcc.git] / gcc / testsuite / gcc.dg / pr21643.c
blobbe5a15e98d2f848431bd7725dd97e75ba6930f04
1 /* PR tree-optimization/21643 */
2 /* { dg-do compile } */
3 /* { dg-options "-O2 -fdump-tree-reassoc1-details" } */
5 int
6 f1 (unsigned char c)
8 if (c == 0x22 || c == 0x20 || c < 0x20)
9 return 1;
10 return 0;
13 int
14 f2 (unsigned char c)
16 if (c == 0x22 || c <= 0x20)
17 return 1;
18 return 0;
21 int
22 f3 (unsigned char c)
24 if (c == 0x22)
25 return 1;
26 if (c == 0x20)
27 return 1;
28 if (c < 0x20)
29 return 1;
30 return 0;
33 int
34 f4 (unsigned char c)
36 if (c == 0x22 || c == 0x20 || c < 0x20)
37 return 2;
38 return 0;
41 int
42 f5 (unsigned char c)
44 if (c == 0x22 || c <= 0x20)
45 return 2;
46 return 0;
49 int
50 f6 (unsigned char c)
52 if (c == 0x22)
53 return 2;
54 if (c == 0x20)
55 return 2;
56 if (c < 0x20)
57 return 2;
58 return 0;
61 int
62 f7 (unsigned char c)
64 if (c != 0x22 && c != 0x20 && c >= 0x20)
65 return 0;
66 return 1;
69 int
70 f8 (unsigned char c)
72 if (c == 0x22 && c <= 0x20)
73 return 0;
74 return 1;
77 int
78 f9 (unsigned char c)
80 if (c == 0x22)
81 return 0;
82 if (c == 0x20)
83 return 0;
84 if (c < 0x20)
85 return 0;
86 return 1;
89 /* { dg-final { scan-tree-dump-times "Optimizing range tests c_\[0-9\]*.D. -.0, 31. and -.32, 32.\[\n\r\]* into" 6 "reassoc1" } } */
90 /* { dg-final { cleanup-tree-dump "reassoc1" } } */