add explicit profiler enabling, necessary on 2.2
Merge pull request #2284 from ricardclau/2.2

[2.2] add explicit profiler enabling, necessary on 2.2