mirror of
https://github.com/YosysHQ/yosys
synced 2025-06-21 05:13:40 +00:00
Add log_debug() framework
Signed-off-by: Clifford Wolf <clifford@clifford.at>
This commit is contained in:
parent
c0f9a74b12
commit
e158ea2097
11 changed files with 183 additions and 53 deletions
|
@ -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())
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue