I have encountered some issues with the following code (using PGI 19.10 on Linux):

```
program forall_matmul
implicit none
real, dimension(3,3,3,3) :: C, r
real, dimension(3,3) :: F
integer :: i,j
C=1.0
F=1.0
! compile with -Mbounds to get a runtime error
forall(i=1:3,j=1:3)
r(i,j,1:3,1:3) = matmul(F,C(i,j,1:3,1:3))
endforall
print*, r ! all r should be 3 (some 2 appear)
end program forall_matmul
```

Compiling with

-Mbounds

gives the following error message during runtime

```
0: Subscript out of range for array c (forall_matmul.f90: 12)
subscript=32766, lower bound=1, upper bound=3, dimension=1
```