Optimize output size of kpm pack

parent #652 
Fixed