2010-12-20 Tobias Burnus <burnus@net-b.de>
[official-gcc.git] / gcc / testsuite / gfortran.dg / whole_file_6.f90
blob266c289f541219dce74b6fedbe1beb8cf8e2001e
1 ! { dg-do "compile" }
2 ! { dg-options "-O3 -fwhole-file -fdump-tree-optimized" }
3 ! { dg-add-options bind_pic_locally }
5 ! Check that inlining of functions declared AFTER usage works.
6 ! If yes, then the dump does not contain a call to F().
9 PROGRAM main
10 INTEGER :: a(3), f
11 a = f()
12 print *, a
13 END PROGRAM
15 INTEGER FUNCTION f()
16 f = 42
17 END FUNCTION
19 ! { dg-final { scan-tree-dump-times "= f \\(\\)" 0 "optimized" } }
20 ! { dg-final { cleanup-tree-dump "optimized" } }