Normally performance reporting is enabled from the Services window, but if writing your own editor extension, this API can be used.
enabled | This Boolean field causes the performance reporting feature in Unity to be enabled if true, or disabled if false. |