File gpi_logging.c¶
GPI logging
Write a log message using cocotb SimLog class
GILState before calling: Unknown
GILState after calling: Unknown
Makes one call to PyGILState_Ensure and one call to PyGILState_Release
If the Python logging mechanism is not initialised, dumps to stderr
.
-
void
gpi_log
(const char *name, long level, const char *pathname, const char *funcname, long lineno, const char *msg, ...)¶
Defines
-
LOG_SIZE
512¶
Functions
-
void
set_log_handler
(void *handler)¶
-
void
clear_log_handler
(void)¶
-
void
set_log_filter
(void *filter)¶
-
void
clear_log_filter
(void)¶
-
void
set_log_level
(enum gpi_log_levels new_level)¶
-
const char *
log_level
(long level)¶
Variables
-
PyObject *
pLogHandler
= NULL¶
-
PyObject *
pLogFilter
= NULL¶
-
gpi_log_levels
local_level
= GPIInfo¶
-
struct _log_level_table log_level_table[]= { { 10, "DEBUG" }, { 20, "INFO" }, { 30, "WARNING" }, { 40, "ERROR" }, { 50, "CRITICAL" }, { 0, NULL}}
-
char
log_buff
[LOG_SIZE
]¶
-
struct
_log_level_table
¶