| <- HREF="index.html" PREV | Index | Next -> |
NHSE ReviewTM: Comments · Archive · Search


      program three_assignments
      common /pghpf_0/pghpf_0, /pghpf_0c/pghpf_0c
     +, /pghpf_lineno/pghpf_lineno, /pghpf_0l/pghpf_0l
      integer pghpf_0(4), pghpf_lineno, pghpf_0l(8)
      character*1 pghpf_0c
      common /pghpf_local_mode / pghpf_local_mode
      integer pghpf_local_mode
      integer i$i, i$i1, i$i2, i$i3, i$i4, i$i5, i$i6, i$$l, i$$u, i$$l1
     +, i$$u1, a1$tl$d(1), a1$d(1), c2$d(1), a1$d1(1), c2$d1(1), c1$d(1)
     +, a1$d2(1), l$$b, u$$b, l$$b1, u$$b1, l$$b2, u$$b2, l$$b3, u$$b3, 
     +l$$b4, u$$b4, l$$b5, u$$b5
      real a1(1), a2(1), b1(1), b2(1), c1(1), c2(1)
      integer a1$p, a2$p, b1$p, b2$p, c1$p, c2$p, a1$tl$dp, a1$dp, c2$dp
     +, a1$dp1, c2$dp1, c1$dp, a1$dp2
      data pghpf_0l /852079691,-1644679408,927163014,-264199905,1,
     +1261038733,0,1679348513/
      call pghpf_init(0)
      pghpf_local_mode = 0
      call pghpf_template(a1$dp1,2,1024,0,0,0,1,30,1,40)
      call pghpf_ptr_offset(a1$dp1,a1$dp1,a1$d1,25)
      call pghpf_instance(a1$dp2,a1$d1(a1$dp1),27,4,0,0,0,0,0)
      call pghpf_ptr_offset(a1$dp2,a1$dp2,a1$d2,25)
      call pghpf_template(c2$dp,2,20480,a1$d1(a1$dp1),0,1,30,1,40)
      call pghpf_ptr_offset(c2$dp,c2$dp,c2$d,25)
      call pghpf_instance(c2$dp1,c2$d(c2$dp),27,4,0,4,4,4,4)
      call pghpf_ptr_offset(c2$dp1,c2$dp1,c2$d1,25)
      call pghpf_instance(c1$dp,c2$d(c2$dp),27,4,0,0,0,0,0)
      call pghpf_ptr_offset(c1$dp,c1$dp,c1$d,25)
      call pghpf_allobnds(a1$d2(a1$dp2),l$$b,u$$b,l$$b1,u$$b1)
      call pgf90_alloc((u$$b-l$$b+1)*(u$$b1-l$$b1+1),27,pghpf_0(3),
     +pghpf_0(3),a1$p,a1)
      call pghpf_allobnds(c2$d1(c2$dp1),l$$b2,u$$b2,l$$b3,u$$b3)
      call pgf90_alloc((u$$b2-l$$b2+1)*(u$$b3-l$$b3+1),27,pghpf_0(3),
     +pghpf_0(3),a2$p,a2)
      call pghpf_allobnds(c1$d(c1$dp),l$$b4,u$$b4,l$$b5,u$$b5)
      call pgf90_alloc((u$$b4-l$$b4+1)*(u$$b5-l$$b5+1),27,pghpf_0(3),
     +pghpf_0(3),b1$p,b1)
      call pgf90_alloc((u$$b2-l$$b2+1)*(u$$b3-l$$b3+1),27,pghpf_0(3),
     +pghpf_0(3),b2$p,b2)
      call pgf90_alloc((u$$b4-l$$b4+1)*(u$$b5-l$$b5+1),27,pghpf_0(3),
     +pghpf_0(3),c1$p,c1)
      call pgf90_alloc((u$$b2-l$$b2+1)*(u$$b3-l$$b3+1),27,pghpf_0(3),
     +pghpf_0(3),c2$p,c2)

      call pghpf_localize_bounds(c2$d1(c2$dp1),1,1,30,1,i$$l,i$$u)
      call pghpf_localize_bounds(c2$d1(c2$dp1),2,1,40,1,i$$l1,i$$u1)

!     forall (i$i=i$$l1:i$$u1:1, i$i1=i$$l:i$$u:1) a2((u$$b2-l$$b2+1)*(
!    +i$i-l$$b3)+i$i1-l$$b2+a2$p) = a1((u$$b-l$$b+1)*(i$i-l$$b1)+i$i1-
!    +l$$b+a1$p)
      do i$i = i$$l1, i$$u1
         do i$i1 = i$$l, i$$u
            a2((u$$b2-l$$b2+1)*(i$i-l$$b3)+i$i1-l$$b2+a2$p) = a1((u$$b-
     +l$$b+1)*(i$i-l$$b1)+i$i1-l$$b+a1$p)
            b2((u$$b2-l$$b2+1)*(i$i-l$$b3)+i$i1-l$$b2+b2$p) = b1((u$$b4-
     +l$$b4+1)*(i$i-l$$b5)+i$i1-l$$b4+b1$p)
            c2((u$$b2-l$$b2+1)*(i$i-l$$b3)+i$i1-l$$b2+c2$p) = c1((u$$b4-
     +l$$b4+1)*(i$i-l$$b5)+i$i1-l$$b4+c1$p)
         enddo
      enddo

      call use_them(a2(a2$p),b2(b2$p),c2(c2$p),c2$d1(c2$dp1),c2$d1(
     +c2$dp1),c2$d1(c2$dp1))
99999 continue
      call pgf90_deallocate(a1(a1$p),pghpf_0(3))
      call pgf90_deallocate(a2(a2$p),pghpf_0(3))
      call pgf90_deallocate(b1(b1$p),pghpf_0(3))
      call pgf90_deallocate(b2(b2$p),pghpf_0(3))
      call pgf90_deallocate(c1(c1$p),pghpf_0(3))
      call pgf90_deallocate(c2(c2$p),pghpf_0(3))
      call pghpf_free(c1$d(c1$dp))
      call pghpf_free(c2$d1(c2$dp1))
      call pghpf_free(c2$d(c2$dp))
      call pghpf_free(a1$d2(a1$dp2))
      call pghpf_free(a1$d1(a1$dp1))
      call pgf90_exit(0)
      end

| <- HREF="index.html" PREV | Index | Next -> |
NHSE ReviewTM: Comments · Archive · Search


presberg@tc.cornell.edu
Last modified: Fri Jan 31, 1997