Skip to content

Commit 1cd2fb0

Browse files
committed
address review comments
Signed-off-by: Alessandro Comodi <[email protected]>
1 parent 2b7a37c commit 1cd2fb0

File tree

3 files changed

+28
-6
lines changed

3 files changed

+28
-6
lines changed

libs/libarchfpga/src/physical_types.h

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1764,6 +1764,21 @@ struct t_arch {
17641764
t_clock_arch* clocks = nullptr;
17651765

17661766
// Constants
1767+
// VCC and GND cells are special virtual cells that are
1768+
// used to handle the constant network of the device.
1769+
//
1770+
// Similarly, the constant nets are defined to identify
1771+
// the generic name for the constant network.
1772+
//
1773+
// Given that usually, the constants have a dedicated network in
1774+
// real FPGAs, this information becomes relevant to identify which
1775+
// nets from the circuit netlist are belonging to the constant network,
1776+
// and assigned to it accordingly.
1777+
//
1778+
// NOTE: At the moment, the constant cells and nets are primarly used
1779+
// for the interchange netlist format, to determine which are the constants
1780+
// net names and which virtual cell is responsible to generate them.
1781+
// The information is present in the device database.
17671782
std::string gnd_cell;
17681783
std::string vcc_cell;
17691784

vpr/src/base/read_circuit.cpp

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ AtomNetlist read_and_process_circuit(e_circuit_format circuit_format, t_vpr_setu
3838
if (circuit_format == e_circuit_format::AUTO) {
3939
auto name_ext = vtr::split_ext(circuit_file);
4040

41-
VTR_LOG("%s\n", circuit_file);
41+
VTR_LOGV(verbosity, "Circuit file: %s\n", circuit_file);
4242
if (name_ext[1] == ".blif") {
4343
circuit_format = e_circuit_format::BLIF;
4444
} else if (name_ext[1] == ".eblif") {
@@ -62,7 +62,9 @@ AtomNetlist read_and_process_circuit(e_circuit_format circuit_format, t_vpr_setu
6262
netlist = read_interchange_netlist(circuit_file, arch);
6363
break;
6464
default:
65-
VTR_ASSERT(false);
65+
VPR_FATAL_ERROR(VPR_ERROR_ATOM_NETLIST,
66+
"Unable to identify circuit file format for '%s'. Expect [blif|eblif|fpga-interchange]!\n",
67+
circuit_file);
6668
break;
6769
}
6870
}

vpr/src/util/vpr_error.h

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,17 +9,22 @@
99

1010
enum e_vpr_error {
1111
VPR_ERROR_UNKNOWN = 0,
12+
13+
// Flow errors
1214
VPR_ERROR_ARCH,
1315
VPR_ERROR_PACK,
1416
VPR_ERROR_PLACE,
1517
VPR_ERROR_ROUTE,
1618
VPR_ERROR_TIMING,
1719
VPR_ERROR_POWER,
1820
VPR_ERROR_SDC,
19-
VPR_ERROR_NET_F,
20-
VPR_ERROR_PLACE_F,
21-
VPR_ERROR_BLIF_F,
22-
VPR_ERROR_IC_NETLIST_F,
21+
22+
// File parsing errors
23+
VPR_ERROR_NET_F, // Error while parsing the packed netlist file
24+
VPR_ERROR_PLACE_F, // Error while parsning the placement file
25+
VPR_ERROR_BLIF_F, // Error while parsing the blif file
26+
VPR_ERROR_IC_NETLIST_F, // Error while parsing the interchange netlist file
27+
2328
VPR_ERROR_IMPL_NETLIST_WRITER,
2429
VPR_ERROR_NETLIST,
2530
VPR_ERROR_ATOM_NETLIST,

0 commit comments

Comments
 (0)