Properly check that profiling is enabled