COPY_IN error with PGHPF

Hi, I find the following message when running a program compiled with pghpf:

COPY_IN: argument shape conformance error

I think that it has something to do with the socket. I’m using LAM/MPI on fedora 5 and I was able to run some simple hpf programs(e.g. matrix multiplication).

This is how I distribute the data:

!HPF$ DISTRIBUTE (BLOCK,BLOCK) :: EQ
!HPF$ ALIGN QQ(:) WITH EQ(:,*)

And this is one of the many loops where the arrays are used:

DO 380 L = LPIVC, LCOL
EQ(L-1,K-1) = EQ(L,K) - FAC * QQ(L)
380 CONTINUE

Any help will be appreciated.

Hi! I’m not sure why you think this has something to do with the socket, though perhaps you know something there. The error message you see comes out at a subroutine or function call where the dummy argument has an explicit shape, and the actual argument has a different shape. An example:

real a(100)
call foo(a)
end
subroutine foo(b)
real b(99)
end subroutine

The shape of the dummy is (99), while the shape of the actual is (100). Other examples:

real a(100)
call foo(a(2:99)) ! shape is (98)
end
subroutine foo(b)
real b(99) ! shape is (99)
end subroutine

real a(100)
call foo(a(2:99),99) ! shape is 98
call foo(a(2:99),98) ! shape is still 98
end
subroutine foo(b,n)
real b(n) ! shape is 99 for 1st call, 98 for second
end subroutine

The problem is that it runs well when compiled with pgf90(e.g, and not taking into account the data distribution directives).
So, I take a program which is running all right then distribute the data and find an error.
As long as I know(and I may be wrong)PGHPF is not supposed to behave in this way.

Any help will be appreciated.

Cheers!!

Hi Alberto,

With F90, if the shape of the actual and dummy arguments are different, then the shape of the dummy argument is used. In HPF, the shapes of the actual and dummy arguments must be the same. Please check your code to make sure the two shapes match.

  • Mat