I keep writing code that computes the duration taken by a chunk of code, averaging over some number of calls and printing the result using WTFLogAlways. This should be wrapped in stack-based helper class.
Created attachment 327189 [details] Patch
Maybe this and B3TimingScope should share code at some point, but I don't think that's necessary for a small utility class right now.
Attachment 327189 [details] did not pass style-queue: ERROR: Source/WTF/wtf/TimingScope.cpp:67: More than one command on the same line [whitespace/newline] [4] Total errors found: 1 in 5 files If any of these errors are false positives, please file a bug against check-webkit-style.
Comment on attachment 327189 [details] Patch Clearing flags on attachment: 327189 Committed r224990: <https://trac.webkit.org/changeset/224990>
All reviewed patches have been landed. Closing bug.
<rdar://problem/35624957>