libgfortran/ChangeLog:
[official-gcc.git] / gcc / testsuite / gfortran.dg / power_6.f90
blob65d1bd02684f57b21af9d9de6a5ed3a6bceb48c8
1 ! { dg-do compile }
2 ! { dg-options "-O1 -fdump-tree-optimized" }
4 ! PR middle-end/57073
5 ! See also PR 57073
7 real function f(k)
8 integer, value :: k
9 f = (-1.0)**k
10 end
12 ! { dg-final { scan-tree-dump-not "__builtin_powif" "optimized" } }
13 ! { dg-final { scan-tree-dump "powi_cond_\[0-9\] = k_\[0-9\]\\(D\\) & 1;" "optimized" } }
14 ! { dg-final { scan-tree-dump "powi_\[0-9\] = powi_cond_\[0-9\] \\? -1.0e\\+0 : 1.0e\\+0;" "optimized" } }
15 ! { dg-final { cleanup-tree-dump "optimized" } }