to kmp