Debian Codegraph @

gcc/testsuite/gfortran.dg/graphite/vect-pr40979.f90

raw
1 ! { dg-do compile }
2 ! { dg-require-effective-target vect_double }
3 ! { dg-additional-options "-msse2" { target { { i?86-*-* x86_64-*-* } && ilp32 } } }
4 ! { dg-additional-options "-mlsx" { target { loongarch*-*-* } } }
5
6 module mqc_m
7 integer, parameter, private :: longreal = selected_real_kind(15,90)
8 contains
9 subroutine mutual_ind_quad_cir_coil (m, l12)
10 real (kind = longreal), dimension(9), save :: w2gauss, w1gauss
11 real (kind = longreal) :: l12_lower, num, l12
12 real (kind = longreal), dimension(3) :: current, coil
13 w2gauss(1) = 16.0_longreal/81.0_longreal
14 w1gauss(5) = 0.3302393550_longreal
15 do i = 1, 2*m
16 do j = 1, 9
17 do k = 1, 9
18 num = w1gauss(j) * w2gauss(k) * dot_product(coil,current)
19 l12_lower = l12_lower + num
20 end do
21 end do
22 end do
23 l12 = l12_lower
24 end subroutine mutual_ind_quad_cir_coil
25 end module mqc_m
26
27 ! { dg-final { scan-tree-dump-times "vectorized 1 loops" 1 "vect" } }