Add a new eventhandler and convert hwpmc to use it.