[mythtv] [patch] verbose/debug

Kenneth Aafløy ke-aa at frisurf.no
Tue Mar 9 21:54:57 EST 2004


On Wednesday 10 March 2004 03:29, Matt Zimmerman wrote:
> On Wed, Mar 10, 2004 at 03:06:50AM +0100, Kenneth Aafl?y wrote:
> > On Wednesday 10 March 2004 02:45, Matt Zimmerman wrote:
> > > On Fri, Mar 05, 2004 at 10:22:08PM +0100, Kenneth Aafl?y wrote:
> > > > here is a patch that makes it easier to add options to the verbose()
> > > > macro (not that it happens very often :), and also adds a debug()
> > > > macro much like the verbose(). The idea beeing that the debug() macro
> > > > should help identify a problem without recompiling the libs+app with
> > > > debugging statements For now i've not done anything to remove this
> > > > feature if the application is built as a release, but feel free to
> > > > add that. I've also made the helptext a bit more readable.
> > >
> > > Wouldn't this be implemented more simply using additional levels of
> > > verbose logging, rather than a separate logging system?
> >
> > Much easier to just clear out all debug messages in release binaries if
> > they are contained in a separate macro.
>
> Why would you need to do that, if they are not output by default anyway?

It seems to me this is the current practice in most projects (ie. clearing out 
any debug messages) for builds that is not a debug build. Because most likes 
the speed of clean code, when published, but i guess an if statement won't do 
anything else that clobber the cpu prediction engine if the debug statements 
occur in critical sections.

-- 

Kenneth
ke-aa at frisurf.no


More information about the mythtv-dev mailing list