adding code for kernel launch