Add sanitizer_kernel.cc with some kernel-specific functions.