[placer1] Ignore timing of TMG_IGNORE nets
This commit is contained in:
parent
15d9b3d3cc
commit
200fb3f664
@ -28,19 +28,19 @@ NEXTPNR_NAMESPACE_BEGIN
|
|||||||
wirelen_t get_net_metric(const Context *ctx, const NetInfo *net, MetricType type, float &tns)
|
wirelen_t get_net_metric(const Context *ctx, const NetInfo *net, MetricType type, float &tns)
|
||||||
{
|
{
|
||||||
wirelen_t wirelength = 0;
|
wirelen_t wirelength = 0;
|
||||||
Loc driver_loc;
|
|
||||||
bool driver_gb;
|
|
||||||
CellInfo *driver_cell = net->driver.cell;
|
CellInfo *driver_cell = net->driver.cell;
|
||||||
if (!driver_cell)
|
if (!driver_cell)
|
||||||
return 0;
|
return 0;
|
||||||
if (driver_cell->bel == BelId())
|
if (driver_cell->bel == BelId())
|
||||||
return 0;
|
return 0;
|
||||||
driver_gb = ctx->getBelGlobalBuf(driver_cell->bel);
|
bool driver_gb = ctx->getBelGlobalBuf(driver_cell->bel);
|
||||||
driver_loc = ctx->getBelLocation(driver_cell->bel);
|
|
||||||
if (driver_gb)
|
if (driver_gb)
|
||||||
return 0;
|
return 0;
|
||||||
|
IdString clock_port;
|
||||||
|
bool driver_tmg_ignore = ctx->getPortTimingClass(driver_cell, net->driver.port, clock_port);
|
||||||
delay_t negative_slack = 0;
|
delay_t negative_slack = 0;
|
||||||
delay_t worst_slack = std::numeric_limits<delay_t>::max();
|
delay_t worst_slack = std::numeric_limits<delay_t>::max();
|
||||||
|
Loc driver_loc = ctx->getBelLocation(driver_cell->bel);
|
||||||
int xmin = driver_loc.x, xmax = driver_loc.x, ymin = driver_loc.y, ymax = driver_loc.y;
|
int xmin = driver_loc.x, xmax = driver_loc.x, ymin = driver_loc.y, ymax = driver_loc.y;
|
||||||
for (auto load : net->users) {
|
for (auto load : net->users) {
|
||||||
if (load.cell == nullptr)
|
if (load.cell == nullptr)
|
||||||
@ -48,7 +48,7 @@ wirelen_t get_net_metric(const Context *ctx, const NetInfo *net, MetricType type
|
|||||||
CellInfo *load_cell = load.cell;
|
CellInfo *load_cell = load.cell;
|
||||||
if (load_cell->bel == BelId())
|
if (load_cell->bel == BelId())
|
||||||
continue;
|
continue;
|
||||||
if (ctx->timing_driven && type == MetricType::COST) {
|
if (!driver_tmg_ignore && ctx->timing_driven && type == MetricType::COST) {
|
||||||
delay_t net_delay = ctx->predictDelay(net, load);
|
delay_t net_delay = ctx->predictDelay(net, load);
|
||||||
auto slack = load.budget - net_delay;
|
auto slack = load.budget - net_delay;
|
||||||
if (slack < 0)
|
if (slack < 0)
|
||||||
|
Loading…
Reference in New Issue
Block a user