[Ffmpeg-cvslog] r5740 - in trunk/libavutil: Makefile lls.c lls.h
Måns Rullgård
mru
Fri Jul 14 22:35:01 CEST 2006
Michael Niedermayer <michaelni at gmx.at> writes:
> i agree but theres a problem, some asserts are irrelevant
> speedwise and some are in speed-critical parts, and there are some people
> (me for example, and possibly other developers...) who want the rarely
> executed asserts() to be enabled while the often executed ones should be
> disabled in their build ... a global NDEBUG is not enough here
>
> IIRC ive already at least suggested once that 2 av_asserts, one for
> speedcritical and one for non-speedcritical parts should be added
> yeah i shouldnt suggest but rather do the work myself i know ...
We could also use a single av_assert with a numerical argument
specifying the debug level at which to enable it.
Something like
#ifndef AV_DEBUG
#define AV_DEBUG 0
#endif
#define av_assert(level, expr) do { \
if(level < AV_DEBUG){ \
assert(expr) \
} \
} while(0)
Then again, perhaps two levels is enough.
--
M?ns Rullg?rd
mru at inprovide.com
More information about the ffmpeg-cvslog
mailing list