How to show last comment on hover?

The comments_popup_link_attributes filter will allow you to output attributes within the link.

function add_comment_hover_action() {
  echo ' onHover="fireMyJSCode();"';
}
add_filter(‘comments_popup_link_attributes’, ‘add_comment_hover_action’);

Alternately, you could hook into the comments_number filter to add a span wrapper around the comment number text with a common class name and the parent post id as an attribute. Then in JavaScript you could assign a function to handle hover actions for all those comment spans. Inside your js function hover handler access the post id from the wrapper element.