arguments passing.

arguments passing.

Why my previous post has no subject? I hope this one works.

------------

Hi, I got this run error at line 2: "call mysub(...)".
line 1 print gives " 37617776 u1: 33423424"
debug at line 30 gives:
d=1 LOC(x0) = 33423424, LOC(x1)=2147348480

It looks like something wrong at passing arguments
Does anyone know what may cause this?
thanks a bunch!

--------------------------------------------------

1: print *, LOC(u0), ' u1=', LOC(u1)

2: call mysub(1,u0,u1, n)

........................

30: subroutine mysub(d, x0,x1,p)

6 posts / 0 new
Last post
For more complete information about compiler optimizations, see our Optimization Notice.

I don't quite understand the question, nor do I see a "run error"

I can surmise that at line 30, x1 has been copied onto the stack, but I'd need to see the whole program to understand why.

Steve

Steve Intel Developer Support

Hi Steve

The runtime error is "forrtl: severe (157): Program Exception - access violation"
Here is the code:

............

 type t_bigarrays 
            	double complex	u0(ntotal/p1) 
              	double complex	u1(ntotal/p1) 
 end type t_bigarrays 
 type (t_bigarrays), pointer :: pbigarrays 
 ALLOCATE(pbigarrays) 
 
 call fft(1, pbigarrays%u1, pbigarrays%u0, pnumber%np) 
 
!--------------------------------------------------------------------- 
fft(d, x0, x1, p) 
!--------------------------------------------------------------------- 
 
      implicit none 
      include 'global.h' 
      integer p 
      integer d 
      double complex x0(ntotal/p), x1(ntotal/p) 

I can see LOC(u0), LOC(u1) push into stack correctly. But after jump to fft, I can not figure out how those values are popped.
Before passing, u0: 37617776 u1: 33423424
After jump to fft, LOC(x0) = 33423424, LOC(x1)=2147348480

Thanks,

Not enough information - please send a ZIP file of your project and a description of the problem to us at vf-support@compaq.com and we'll take a look.

Steve

Steve Intel Developer Support

I'd like to send the whole file, but the first part of code needs special hardware. It won't be able to run at your machine.

thanks anyway.

Well, in that case I suggest you start with my article on Access Violations at http://www.compaq.com/fortran/visual/vfn06/index.html#accvio

Please send the project anyway - or at least the source files needed to compile the caller and callee, and the project settings used. I may spot something that doesn't need it to be run.

Steve

Steve Intel Developer Support

Login to leave a comment.