libcpp, c, middle-end: Optimize initializers using #embed in C
[official-gcc.git] / gcc / testsuite / gcc.dg / tree-ssa / pr96094.c
blobfe9163dda3e4bf5f5857a19a47cc3c2303247313
1 /* PR tree-optimization/96094 */
2 /* { dg-do compile } */
3 /* { dg-options "-O2 -fdump-tree-optimized" } */
4 /* { dg-final { scan-tree-dump-times "return 34;" 2 "optimized" } } */
5 /* { dg-final { scan-tree-dump-times "return y_\[0-9]*\\\(D\\\);" 2 "optimized" } } */
6 /* { dg-final { scan-tree-dump-times "return \[^\n\r;]*;" 4 "optimized" } } */
8 int
9 foo (int x)
11 if (x >= 2U)
12 return 34;
13 return 34 / x;
16 int
17 bar (int x, int y)
19 if (x >= 2U)
20 return y;
21 return y / x;
24 int
25 baz (_Bool x)
27 return 34 / x;
30 int
31 qux (_Bool x, int y)
33 return y / x;