libcpp, c, middle-end: Optimize initializers using #embed in C
[official-gcc.git] / gcc / testsuite / gcc.dg / tree-ssa / pr88087.c
blobc48dba5bf21c339197d337b616f5fd71a08cd45e
1 /* { dg-do compile } */
2 /* { dg-options "-O2 -fno-code-hoisting -fdump-tree-pre-stats" } */
4 int f();
5 int d;
6 void c(int x)
8 int (*fp)() __attribute__((const)) = (void *)f;
9 if (x)
10 d = fp ();
11 int tem = fp ();
12 f();
13 d = tem;
16 /* We shouldn't ICE and PRE the const call. */
17 /* { dg-final { scan-tree-dump "Eliminated: 1" "pre" } } */