After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 335480 - start with debugging disabled
start with debugging disabled
Status: RESOLVED FIXED
Product: GStreamer
Classification: Platform
Component: gstreamer (core)
git master
Other Linux
: Normal normal
: 0.10.5
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2006-03-22 10:05 UTC by Wim Taymans
Modified: 2006-03-22 18:26 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
disable debugging by default (1.13 KB, patch)
2006-03-22 10:07 UTC, Wim Taymans
none Details | Review

Description Wim Taymans 2006-03-22 10:05:23 UTC
Debugging messages consume way too much CPU when no debugging is enabled. This is due to the fact that the global debugging variable is set to TRUE which makes all debugging statement perform an excessive amount of argument formatting and category checking before throwing away the debug info.
Comment 1 Wim Taymans 2006-03-22 10:07:14 UTC
Created attachment 61752 [details] [review]
disable debugging by default

This patch disables the debugging and only enables it when some debug level is set to a value other than NONE.
Comment 2 Wim Taymans 2006-03-22 10:08:35 UTC
Since default core (I think only CVS) sets the default level to ERROR, this patch does not do anything for CVS versions. I'm told we ship with level NONE though.
Comment 3 Wim Taymans 2006-03-22 10:09:38 UTC
As Jan suggested, a non ABI change would be to check a global level and compare it do the current debug level of the message.
Comment 4 Wim Taymans 2006-03-22 18:26:14 UTC

        * gst/gstinfo.c: (gst_debug_set_active),
        (gst_debug_category_set_threshold):
        Disable debugging unless explicitly activated.
        Fixes #335480.