When a sampling profiler is used, it differs from an instrumentation profiler in two ways: - first, there is no data for 'calls count' and 'average call duration' data grid columns; - second, displaying fractions of milliseconds is meaningless, because a sampling profiler can't provide such accuracy. Thus, my proposal is to introduce a corresponding preference, and to update profiles panel code as necessary.
Created attachment 39053 [details] Proposed change
Comment on attachment 39053 [details] Proposed change samplingCpuProfiler should be samplingCPUProfiler per our style guidlines. > "function": { title: WebInspector.UIString("Function"), disclosure: true, sortable: true } }; > + if (Preferences.samplingCpuProfiler) { > + delete columns.average; > + delete columns.calls; > + } Add an empty line before the if.
Created attachment 39059 [details] Proposed change Comment addressed
Comment on attachment 39059 [details] Proposed change You missed my more important samplingCpuProfiler -> samplingCPUProfiler comment.
Created attachment 39063 [details] Comment now addressed. Oh, I'm sorry. Yes, I've missed that line.
Comment on attachment 39063 [details] Comment now addressed. Opps. Sorry I missed this earlier.. + if (Preferences.samplingCPUProfiler) { + delete columns.average; + delete columns.calls; + } You need to use 4 space indents.
Created attachment 39073 [details] Indentation fixed Oh, I'm really really sorry. I should have different editor settings for WebKit patches.
Committing to http://svn.webkit.org/repository/webkit/trunk ... M WebCore/ChangeLog M WebCore/inspector/front-end/ProfileDataGridTree.js M WebCore/inspector/front-end/ProfileView.js M WebCore/inspector/front-end/inspector.js Committed r48074