error = access violation on load (global memory)

Hi,

I am developing an algorithm based on recursion and I should use cuda dynamic parallelism.

The program is working fine if I used function calls whoever, If I lunch a new kernel I got many errors for accessing global memory.

Here is a log for the program :-

The remote system's TDR is enabled, and the delay is set to 20 seconds. This will timeout when setting breakpoints on the target. Please modify the system's TDR setting or disable TDR.
The remote system's TDR is enabled, and the delay is set to 20 seconds. This will timeout when setting breakpoints on the target. Please modify the system's TDR setting or disable TDR.
CUDA context created : 00e04c28
CUDA module loaded:   048f5100 Debug/kernel.cu.obj 
================================================================================
CUDA Memory Checker detected 1 threads caused an access violation:
Launch Parameters
    CUcontext    = 00e04c28
    CUstream     = 00000000
    CUmodule     = 048f5100
    CUfunction   = 067e5b98
    FunctionName = _Z14InternalSearchP11MinimaxMoveP13CheckersBoardbiii
    GridId       = -5
    gridDim      = {1,1,1}
    blockDim     = {7,1,1}
    sharedSize   = 256
    Parameters:
        __val_parambestMove = 0x439fb7e0  {Move = 0x439faea0  {...}, Value = 0}
        state = 0x439fb830  {pieces = {4, 4, 4, 4, 4, 4, 4, 4, 4, 4, ...}, whitePieces = 12, blackPieces = 12, currentPlayer = 4}
        __val_paramalpha = -2147483648
        __val_parambeta = 2147483647
        depth = 1
        isLightPlayer = false
    Parameters (raw):
         0x439fb7e0 0x439fb830 0xffff7f00 0x80000000
         0x7fffffff 0x00000001
GPU State:
   Address  Size      Type  Mem       Block  Thread         blockIdx  threadIdx      PC  Source
-----------------------------------------------------------------------------------------------
  439fb83a     2    adr ld    g           0       0          {0,0,0}    {0,0,0}ffffffffffff52a0  c:\users\ahmed\documents\visual studio 2012\projects\cudanegamaxclass\cudanegamaxdp\kernel.cu:570


Summary of access violations:
c:\users\ahmed\documents\visual studio 2012\projects\cudanegamaxclass\cudanegamaxdp\kernel.cu(570): error MemoryChecker: #misaligned=0  #invalidAddress=7
================================================================================

Memory Checker detected 1 access violations.
error = access violation on load (global memory)
gridid = -5
blockIdx = {0,0,0}
threadIdx = {0,0,0}
address = 0x439fb83a
accessSize = 2

Memory Checker detected 0 access violations.
error = access violation on load (global memory)
gridid = 43
blockIdx = {0,0,0}
threadIdx = {0,0,0}
address = 0x439fb83a
accessSize = 2

I also noticed that in the main global function the structure variable “state” is declared as global variable whoever, after the structure variable call a function inside it in the global function it converted to const global variable!!!

Any ideas ? I really need your help guys.