anchor.diff:                      // disposed yet
                       CudaSup.context.PushContext ()
                       CudaSup.context.GetDeviceInfo() |> ignore
  +
  +                    // cleanup CUDA resources
                       execCalls recipe.DisposeCalls
                       Compile.unloadCudaCode krnlModHndl
                       CudaSup.context.PopContext ()
  
positive.code:                         execEnv.Stream.Add(strm, new CudaStream(flags))
                  | StreamDestory strm ->
                      if not Debug.DisableStreams then
                          execEnv.Stream.[strm].Dispose()
                          execEnv.Stream.Remove(strm) |> ignore
                  | StreamWaitEvent (strm, evnt) ->
                      if not Debug.DisableStreams then
                          execEnv.Stream.[strm].WaitEvent(execEnv.Event.[evnt].Event)
  
negative.code:                 | CudaCallT.MemAlloc mem -> 
                      let typeSize = Marshal.SizeOf (TypeName.getType mem.TypeName)
                      let elements = if mem.Elements > 0 then mem.Elements else 1
                      try
                          execEnv.InternalMem.Add(mem, new CudaDeviceVariable<byte>(SizeT (elements * typeSize)))
                      with :? CudaException as e when e.CudaError = CUResult.ErrorOutOfMemory ->
                          failwithf "Out of CUDA memory while allocating %d bytes" (elements * typeSize)
                  | CudaCallT.MemFree mem ->
                      if execEnv.InternalMem.ContainsKey mem then
                          execEnv.InternalMem.[mem].Dispose()
                          execEnv.InternalMem.Remove(mem) |> ignore
  
                  // memory operations
                  | MemcpyAsync (dst, src, strm) ->
  