Pull request for all the remaining patches, including the new performance monitors.

Can we use a const references as the second parameter.