[Webkit-unassigned] [Bug 185704] New: [Cocoa] Consider renaming and only default enabling release logging in Production builds; make release logging opt-in for Debug and Release builds

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Wed May 16 16:49:03 PDT 2018


https://bugs.webkit.org/show_bug.cgi?id=185704

            Bug ID: 185704
           Summary: [Cocoa] Consider renaming and only default enabling
                    release logging in Production builds; make release
                    logging opt-in for Debug and Release builds
           Product: WebKit
           Version: WebKit Local Build
          Hardware: Unspecified
                OS: Unspecified
            Status: NEW
          Severity: Normal
          Priority: P2
         Component: Platform
          Assignee: webkit-unassigned at lists.webkit.org
          Reporter: dbates at webkit.org
                CC: krollin at apple.com

Every time I use Xcode to debug an issue I am greeted with a wall of log messages of the form:

[[
2018-05-16 15:07:43.819732-0700 MiniBrowser[29659:9188375] [Network] 0x1242f5000 - DocumentLoader::startLoadingMainResource: Returning empty document (frame = 0x11f5e7440, main = 1)
2018-05-16 15:07:43.819976-0700 MiniBrowser[29659:9188375] [PerformanceLogging] Memory usage info dump at MainFrameLoadCompleted:
]]

It seems excessive to enable such logging by default for Debug and Release built WebKit. I can see the benefit for such logging for Production builds to help diagnose hard to debug issues in customer installs. Therefore I propose that we enable such logging by default only for Production builds. For all other builds we should disable such logging by default and require a person to explicitly opt-in to such logging if desired. We may also want to consider renaming the RELEASE_LOG*() functions to better reflect their primary purpose to help diagnose hard to debug issues in customer installs.

Additional remarks:

The compile-time option RELEASE_LOG_DISABLED controls whether such release logging is enabled. Such logging is made using the macro functions RELEASE_LOG*(). To clarify, the term "release" is a reference to logging that we want to appear in customer logs for shipped ("release"d) software and is not to be confused with the Xcode build configuration type of the same name (Release). Unless RELEASE_LOG_DISABLED is explicitly defined to be false, RELEASE_LOG_DISABLED is set to the value of !(USE(OS_LOG)) [1]; => RELEASE_LOG*() logs a message on iOS and macOS (by [2]) regardless of the Xcode build configuration WebKit was built with. 

[1] <https://trac.webkit.org/browser/trunk/Source/WTF/wtf/Assertions.h?rev=231130#L102>
[2] <https://trac.webkit.org/browser/trunk/Source/WTF/wtf/Platform.h?rev=231743#L1267>

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20180516/76ff69d8/attachment.html>


More information about the webkit-unassigned mailing list