Faluire in execute (call to cuStreamSynchronize returned error 700: Illegal address during kernel execution)

Hi,

I am trying to accelerate only one function from the code I am using the directive.

#pragma acc data create [some arrays]
#pragma acc kernels

after compilation, the result is as below:

1896, Generating implicit copyin(this[:]) [if not already present]
Generating create(u_field.vector[:local_size],v_field.vector[:local_size],w_field.vector[:local_size],delta_z_field.vector[:local_size],kappa_field.vector[:local_size],T_field.vector[:local_size],delta_x_field.vector[:local_size],delta_y_field.vector[:local_size],rhoE_vis_flux.vector[:local_size],rhou_vis_flux.vector[:local_size],rhov_vis_flux.vector[:local_size],mu_field.vector[:local_size]) [if not already present]

then fail to execute with error (call to cuStreamSynchronize returned error 700: Illegal address during kernel execution)

Why it’s generating (Generating implicit copyin(this[:]) [if not already present]) and I didn’t specify this copy and the function has no pointers. how to turn it off?

Best,

I’m presuming you’re doing this within a class method. In this case, classes have a hidden ‘this’ pointer for which the class’ members are accessed. Hence it needs to be copied to the device as well.

If you can provide more information, and preferably a minimal reproducing example, I can provide better assistance on finding the cause of the error.

I do have some examples for using OpenACC data management within classes that may be useful. See the “accList” examples at: ParallelProgrammingWithOpenACC/Chapter05 at master · rmfarber/ParallelProgrammingWithOpenACC · GitHub

-Mat