     BLOCK_VOL = nx_s*ny_s*nz_s;
     // dimensions for the 1D GPU grid
     ngrid = (BLOCK_VOL + TPB - 1) / TPB;
+    #ifndef DYNAMIC_GPU_ALLOC
     block_size = true;
+    #endif
   }
   // set values for GPU kernels
   // number of blocks per 1D grid  

  #endif


  #ifdef SINGLE_ALLOC_GPU
  chprintf( " VL_3D: Memory freed successfully \n");
  #endif
}

  // free CPU memory
  if (block_tot > 1) free(buffer);
  
  #ifdef DYNAMIC_GPU_ALLOC
  // If memory is not single allocated then free the memory every timestep.
  Free_Memory_VL_3D();
  #endif
