From d3b1e562adce4d99e9e742f668f9b8184bc85b69 Mon Sep 17 00:00:00 2001 From: tangxifan Date: Thu, 2 May 2024 21:11:20 -0700 Subject: [PATCH] [core] fixed some bugs on format --- openfpga/src/fabric/fabric_hierarchy_writer.cpp | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/openfpga/src/fabric/fabric_hierarchy_writer.cpp b/openfpga/src/fabric/fabric_hierarchy_writer.cpp index 12098dda2..e8748c8f2 100644 --- a/openfpga/src/fabric/fabric_hierarchy_writer.cpp +++ b/openfpga/src/fabric/fabric_hierarchy_writer.cpp @@ -71,6 +71,10 @@ static int rec_output_module_hierarchy_to_text_file( break; } } + VTR_LOGV(verbose, "Current depth: %lu, Target depth: %lu\n", current_hie_depth, hie_depth_to_stop); + VTR_LOGV(use_list && verbose, "Use list as module '%s' contains only leaf nodes\n", + module_name_map.name(module_manager.module_name(parent_module)).c_str() + ); /* Iterate over all the child module */ for (const ModuleId& child_module : @@ -203,6 +207,7 @@ int write_fabric_hierarchy_to_text_file( fp, hie_depth_to_stop, hie_depth + 1, /* Start with level 1 */ module_manager, curr_module, module_name_map, module_name_filter, verbose); + VTR_LOGV(verbose, "Select module '%s' as root\n", module_name_map.name(module_manager.module_name(curr_module)).c_str()); /* Catch error code and exit if required */ if (err_code == CMD_EXEC_FATAL_ERROR) { return err_code; @@ -211,12 +216,12 @@ int write_fabric_hierarchy_to_text_file( } if (cnt == 0) { - VTR_LOGV_ERROR( - verbose, + VTR_LOG_ERROR( "Unable to find any module matching the root module name pattern '%s'!\n", root_module_names.c_str()); return CMD_EXEC_FATAL_ERROR; } + VTR_LOG("Outputted %lu modules as root\n", cnt); /* close a file */ fp.close();