File tree Expand file tree Collapse file tree 4 files changed +6
-7
lines changed Expand file tree Collapse file tree 4 files changed +6
-7
lines changed Original file line number Diff line number Diff line change @@ -158,7 +158,6 @@ extern "C" {
158158
159159void yosys_atexit ()
160160{
161- RTLIL::OwningIdString::collect_garbage (false );
162161#if defined(YOSYS_ENABLE_READLINE) || defined(YOSYS_ENABLE_EDITLINE)
163162 if (!yosys_history_file.empty ()) {
164163#if defined(YOSYS_ENABLE_READLINE)
Original file line number Diff line number Diff line change @@ -246,15 +246,14 @@ struct IdStringCollector {
246246int64_t RTLIL::OwningIdString::gc_ns;
247247int RTLIL::OwningIdString::gc_count;
248248
249- void RTLIL::OwningIdString::collect_garbage (bool trace )
249+ void RTLIL::OwningIdString::collect_garbage ()
250250{
251251 int64_t start = PerformanceTimer::query ();
252252#ifndef YOSYS_NO_IDS_REFCNT
253253 IdStringCollector collector;
254- if (trace)
255- for (auto &[idx, design] : *RTLIL::Design::get_all_designs ()) {
256- collector.trace (*design);
257- }
254+ for (auto &[idx, design] : *RTLIL::Design::get_all_designs ()) {
255+ collector.trace (*design);
256+ }
258257 int size = GetSize (global_id_storage_);
259258 for (int i = static_cast <int >(StaticId::STATIC_ID_END); i < size; ++i) {
260259 RTLIL::IdString::Storage &storage = global_id_storage_.at (i);
Original file line number Diff line number Diff line change @@ -574,7 +574,7 @@ struct RTLIL::OwningIdString : public RTLIL::IdString {
574574 }
575575
576576 // Collect all non-owning references.
577- static void collect_garbage (bool trace = true );
577+ static void collect_garbage ();
578578 static int64_t garbage_collection_ns () { return gc_ns; }
579579 static int garbage_collection_count () { return gc_count; }
580580
Original file line number Diff line number Diff line change @@ -260,6 +260,7 @@ void yosys_shutdown()
260260
261261 delete yosys_design;
262262 yosys_design = NULL ;
263+ RTLIL::OwningIdString::collect_garbage ();
263264
264265 for (auto f : log_files)
265266 if (f != stderr)
You can’t perform that action at this time.
0 commit comments