Revert "Update kernel.cpp"

This reverts commit 9ed8b3e8dc2cadf4adde1056cf94033faa4ae16f.