Skip to content

Commit

Permalink
conditional inclusion of sat_router
Browse files Browse the repository at this point in the history
  • Loading branch information
soheilshahrouz committed Jun 5, 2024
1 parent 3b8795f commit b7bf7b5
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 1 deletion.
5 changes: 5 additions & 0 deletions vpr/src/place/noc_place_utils.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,10 @@
#include "noc_routing.h"
#include "place_constraints.h"
#include "move_transactions.h"

#ifdef ENABLE_NOC_SAT_ROUTING
#include "sat_routing.h"
#endif

#include <fstream>

Expand Down Expand Up @@ -929,6 +932,7 @@ bool noc_routing_has_cycle(const vtr::vector<NocTrafficFlowId, std::vector<NocLi
return has_cycles;
}

#ifdef ENABLE_NOC_SAT_ROUTING
void invoke_sat_router(t_placer_costs& costs, const t_noc_opts& noc_opts, int seed) {

auto traffic_flow_routes = noc_sat_route(true, noc_opts, seed);
Expand All @@ -947,6 +951,7 @@ void invoke_sat_router(t_placer_costs& costs, const t_noc_opts& noc_opts, int se
VTR_LOG("SAT routing failed.\n");
}
}
#endif

void print_noc_costs(std::string_view header, const t_placer_costs& costs, const t_noc_opts& noc_opts) {
VTR_LOG("%s. "
Expand Down
2 changes: 2 additions & 0 deletions vpr/src/place/noc_place_utils.h
Original file line number Diff line number Diff line change
Expand Up @@ -578,7 +578,9 @@ bool noc_routing_has_cycle(const vtr::vector<NocTrafficFlowId, std::vector<NocLi
* @param noc_opts Contains NoC-related cost weighting factor used in the SAT router.
* @param seed The initialization seed used in the SAT solver.
*/
#ifdef ENABLE_NOC_SAT_ROUTING
void invoke_sat_router(t_placer_costs& costs, const t_noc_opts& noc_opts, int seed);
#endif

/**
* @brief Prints NoC related costs terms and metrics.
Expand Down
1 change: 0 additions & 1 deletion vpr/src/place/place.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,6 @@
#include "cluster_placement.h"

#include "noc_place_utils.h"
#include "sat_routing.h"

/* define the RL agent's reward function factor constant. This factor controls the weight of bb cost *
* compared to the timing cost in the agent's reward function. The reward is calculated as *
Expand Down

0 comments on commit b7bf7b5

Please sign in to comment.