update profiling, found where runtime is lost
@@ -1324,6 +1324,10 @@ DeviceRRGSB build_device_rr_gsb(boolean output_sb_xml, char* sb_xml_dir,
clock_t t_end;
float run_time_sec;
+ clock_t t_start_profiling;
+ clock_t t_end_profiling;
+ float run_time_sec_profiling = 0.;
+
/* Start time count */
t_start = clock();
@@ -1342,8 +1346,15 @@ DeviceRRGSB build_device_rr_gsb(boolean output_sb_xml, char* sb_xml_dir,
LL_num_rr_nodes, LL_rr_node,
LL_rr_node_indices,
num_segments, LL_rr_indexed_data);
+
+ /* For profiling */
+ t_start_profiling = clock();
/* sort drive_rr_nodes */
sort_rr_gsb_drive_rr_nodes(rr_gsb);
+ /* End time count */
+ t_end_profiling = clock();
+ run_time_sec_profiling += (float)(t_end_profiling - t_start_profiling) / CLOCKS_PER_SEC;
+
/* Add to device_rr_gsb */
DeviceCoordinator sb_coordinator = rr_gsb.get_sb_coordinator();
LL_device_rr_gsb.add_rr_gsb(sb_coordinator, rr_gsb);
@@ -1360,6 +1371,8 @@ DeviceRRGSB build_device_rr_gsb(boolean output_sb_xml, char* sb_xml_dir,
run_time_sec = (float)(t_end - t_start) / CLOCKS_PER_SEC;
vpr_printf(TIO_MESSAGE_INFO, "Backannotation of Switch Block took %g seconds\n\n", run_time_sec);
+ vpr_printf(TIO_MESSAGE_INFO, "Edge sorting for Switch Block took %g seconds\n\n", run_time_sec_profiling);
+
if (TRUE == output_sb_xml) {
create_dir_path(sb_xml_dir);
