> static const char* const priorities[] = {
>     "ERROR",
>     "WARN",
>     "INFO",
>     "DEBUG",
>     "TRACE"
> };

+1

I usually use these levels.

Typical usage:

ERROR:
  Print an error message on returning a value other than
  OMPI_SUCCESS (and OMPI_ERR_TEMP_OUT_OF_RESOURCE etc.).

WARN:
  This does not indicate an error. But users/developers should
  be aware on debugging/tuning. For example, network-level
  timeout, hardware queue full, buggy code.
  Often used with OMPI_ERR_TEMP_OUT_OF_RESOURCE.

INFO:
  Information that may be useful for users and developers.
  Not so verbose. Output only on initialization or
  object creation etc.

DEBUG:
  Information that is useful only for developers.
  Not so verbose. Output once per MPI routine call.

TRACE:
  Information that is useful only for developers.
  Verbose. Output more than once per MPI routine call.

Regards,
KAWASHIMA Takahiro

> so what about :
> 
> static const char* const priorities[] = {
>     "ERROR",
>     "WARN",
>     "INFO",
>     "DEBUG",
>     "TRACE"
> };
> 
> and merge debug and trace if there should be only 4
> 
> Cheers,
> 
> Gilles
> 
> 
> On Monday, June 8, 2015, Ralph Castain <[email protected]> wrote:
> 
> > Could we maybe narrow it down some? If we are going to do it, let’s not
> > make the mistake of the MCA param system and create so many levels. Nobody
> > can figure out the right gradation as it is just too fine grained.
> >
> > I think Nathan’s proposal is the max that makes sense.
> >
> > I’d also like to see us apply the same logic to the MCA param system.
> > Let’s just define ~4 named levels and get rid of the fine grained numbering.
> >
> >
> > On Jun 8, 2015, at 2:04 AM, Gilles Gouaillardet <[email protected]
> > <javascript:_e(%7B%7D,'cvml','[email protected]');>> wrote:
> >
> >  Nathan,
> >
> > i think it is a good idea to use names vs numeric values for verbosity.
> >
> > what about using "a la" log4c verbosity names ?
> > http://sourceforge.net/projects/log4c/
> >
> > static const char* const priorities[] = {
> >     "FATAL",
> >     "ALERT",
> >     "CRIT",
> >     "ERROR",
> >     "WARN",
> >     "NOTICE",
> >     "INFO",
> >     "DEBUG",
> >     "TRACE",
> >     "NOTSET",
> >     "UNKNOWN"
> > };
> >
> > Cheers,
> >
> > Gilles
> >
> > On 5/30/2015 1:32 AM, Nathan Hjelm wrote:
> >
> > At the moment we have a loosely enforced standard for verbosity
> > values. In general frameworks accept anything in the range 0 - 100 with
> > few exceptions. I am thinking about adding an enumerator for verbosities
> > that will accept values in this range and certain named constants which
> > will match with specific verbosity levels. One possible set: none - 0,
> > low - 25, med - 50, high - 75, max - 100. I am open to any set of named
> > verbosities.
> >
> > Thoughts?

Reply via email to