File tree Expand file tree Collapse file tree 2 files changed +16
-6
lines changed Expand file tree Collapse file tree 2 files changed +16
-6
lines changed Original file line number Diff line number Diff line change @@ -320,12 +320,16 @@ static t_ext_pin_util_targets parse_target_external_pin_util(std::vector<std::st
320
320
// For relatively high pin utilizations (e.g. > 70%) this has little-to-no
321
321
// impact on the number of clusters required. As a result we set a default
322
322
// input pin utilization target which is high, but less than 100%.
323
- constexpr float LOGIC_BLOCK_TYPE_AUTO_INPUT_UTIL = 0.8 ;
324
- constexpr float LOGIC_BLOCK_TYPE_AUTO_OUTPUT_UTIL = 1.0 ;
323
+ if (logic_block_type != nullptr ) {
324
+ constexpr float LOGIC_BLOCK_TYPE_AUTO_INPUT_UTIL = 0.8 ;
325
+ constexpr float LOGIC_BLOCK_TYPE_AUTO_OUTPUT_UTIL = 1.0 ;
325
326
326
- t_ext_pin_util logic_block_ext_pin_util (LOGIC_BLOCK_TYPE_AUTO_INPUT_UTIL , LOGIC_BLOCK_TYPE_AUTO_OUTPUT_UTIL);
327
+ t_ext_pin_util logic_block_ext_pin_util (LOGIC_BLOCK_TYPE_AUTO_INPUT_UTIL , LOGIC_BLOCK_TYPE_AUTO_OUTPUT_UTIL);
327
328
328
- targets.set_block_pin_util (logic_block_type->name , logic_block_ext_pin_util);
329
+ targets.set_block_pin_util (logic_block_type->name , logic_block_ext_pin_util);
330
+ } else {
331
+ VTR_LOG_WARN (" Unable to identify logic block type to apply default pin utilization targets to; this may result in denser packing than desired\n " );
332
+ }
329
333
330
334
} else {
331
335
// Process user specified overrides
Original file line number Diff line number Diff line change @@ -752,7 +752,11 @@ t_type_ptr infer_logic_block_type(const DeviceGrid& grid) {
752
752
return logic_block_candidates.front ();
753
753
} else {
754
754
// Otherwise assume it is the most common block type
755
- return find_most_common_block_type (grid);
755
+ auto most_common_type = find_most_common_block_type (grid);
756
+ if (most_common_type == nullptr ) {
757
+ VTR_LOG_WARN (" Unable to infer which block type is a logic block\n " );
758
+ }
759
+ return most_common_type;
756
760
}
757
761
}
758
762
@@ -771,7 +775,9 @@ t_type_ptr find_most_common_block_type(const DeviceGrid& grid) {
771
775
}
772
776
}
773
777
774
- VTR_ASSERT (max_type);
778
+ if (max_type == nullptr ) {
779
+ VTR_LOG_WARN (" Unable to determine most common block type (perhaps the device grid was empty?)\n " );
780
+ }
775
781
return max_type;
776
782
}
777
783
You can’t perform that action at this time.
0 commit comments