blob: 58f5db965868ed1e61e6ad934c7a789f4c3622a2 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
|
/* { dg-do compile } */
/* { dg-options "-O2 -fdump-tree-optimized" } */
static int conststaticvariable;
int f(void)
{
return conststaticvariable;
}
/* There should be no reference to conststaticvariable as we should have
inlined the 0 as IPA reference should have marked the variable as a const
as it is not set in the IR. */
/* { dg-final { scan-tree-dump-times "conststaticvariable" 0 "optimized"} } */
|