URL
https://opencores.org/ocsvn/openrisc/openrisc/trunk
Subversion Repositories openrisc
[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [gfortran.dg/] [function_optimize_2.f90] - Rev 801
Go to most recent revision | Compare with Previous | Blame | View Log
! { dg-do compile }! { dg-options "-O -faggressive-function-elimination -fdump-tree-original" }program mainimplicit nonereal, dimension(2,2) :: a, b, c, dreal :: x, zinteger :: icharacter(60) :: linereal, external :: ext_funcinterfaceelemental function element(x)real, intent(in) :: xreal :: elemend function elementpure function mypure(x)real, intent(in) :: xinteger :: mypureend function mypureelemental impure function elem_impure(x)real, intent(in) :: xreal :: elem_impureend function elem_impureend interfacedata a /2., 3., 5., 7./data b /11., 13., 17., 23./write (unit=line, fmt='(4F7.2)') matmul(a,b) + matmul(a,b)x = 1.2z = sin(x) + cos(x) + sin(x) + cos(x)print *,zx = ext_func(a) + 23 + ext_func(a)print *,d,xz = element(x) + element(x)print *,zi = mypure(x) - mypure(x)print *,iz = elem_impure(x) - elem_impure(x)print *,zend program main! { dg-final { scan-tree-dump-times "matmul_r4" 1 "original" } }! { dg-final { scan-tree-dump-times "__builtin_sinf" 1 "original" } }! { dg-final { scan-tree-dump-times "__builtin_cosf" 1 "original" } }! { dg-final { scan-tree-dump-times "ext_func" 1 "original" } }! { dg-final { scan-tree-dump-times "element" 1 "original" } }! { dg-final { scan-tree-dump-times "mypure" 1 "original" } }! { dg-final { scan-tree-dump-times "elem_impure" 1 "original" } }! { dg-final { cleanup-tree-dump "original" } }
Go to most recent revision | Compare with Previous | Blame | View Log
