Add log_debug() framework
Signed-off-by: Clifford Wolf <clifford@clifford.at>
This commit is contained in:
@@ -56,6 +56,10 @@ int log_verbose_level;
|
||||
string log_last_error;
|
||||
void (*log_error_atexit)() = NULL;
|
||||
|
||||
int log_make_debug = 0;
|
||||
int log_force_debug = 0;
|
||||
int log_debug_suppressed = 0;
|
||||
|
||||
vector<int> header_count;
|
||||
pool<RTLIL::IdString> log_id_cache;
|
||||
vector<shared_str> string_buf;
|
||||
@@ -92,6 +96,9 @@ void logv(const char *format, va_list ap)
|
||||
format++;
|
||||
}
|
||||
|
||||
if (log_make_debug && !ys_debug(1))
|
||||
return;
|
||||
|
||||
std::string str = vstringf(format, ap);
|
||||
|
||||
if (str.empty())
|
||||
|
||||
Reference in New Issue
Block a user