aarch64: Add vector floating point extend pattern [PR113880, PR113869]
[official-gcc.git] / gcc / testsuite / gfortran.dg / minmaxloc_7.f90
blob4270348e12c6351006c84423fa6ca6c9a78948e9
1 ! Contributed by Tobias Burnus <burnus@gcc.gnu.org>
2 ! { dg-do run }
3 program test
4 implicit none
5 real, volatile, allocatable :: A(:)
6 logical, volatile :: mask(11)
8 A = [1,2,3,5,6,1,35,3,7,-3,-47]
9 mask = .true.
10 mask(7) = .false.
11 mask(11) = .false.
12 call sub2 (minloc(A),11)
13 call sub2 (maxloc(A, mask=mask),9)
14 A = minloc(A)
15 if (size (A) /= 1 .or. A(1) /= 11) STOP 1
16 contains
17 subroutine sub2(A,n)
18 integer :: A(:),n
19 if (A(1) /= n .or. size (A) /= 1) STOP 2
20 end subroutine sub2
21 end program test