@@ -380,10 +380,8 @@ static void deserializeUpdates(frDesign* design,
380380 file.close ();
381381}
382382
383- void TritonRoute::updateDesign (const std::vector<std::string>& updatesStrs,
384- int num_threads)
383+ void TritonRoute::updateDesign (const std::vector<std::string>& updatesStrs)
385384{
386- omp_set_num_threads (num_threads);
387385 std::vector<std::vector<drUpdate>> updates (updatesStrs.size ());
388386#pragma omp parallel for schedule(dynamic)
389387 for (int i = 0 ; i < updatesStrs.size (); i++) {
@@ -392,9 +390,8 @@ void TritonRoute::updateDesign(const std::vector<std::string>& updatesStrs,
392390 applyUpdates (updates);
393391}
394392
395- void TritonRoute::updateDesign (const std::string& path, int num_threads )
393+ void TritonRoute::updateDesign (const std::string& path)
396394{
397- omp_set_num_threads (num_threads);
398395 std::vector<std::vector<drUpdate>> updates;
399396 deserializeUpdates (design_.get (), path, updates);
400397 applyUpdates (updates);
@@ -918,8 +915,7 @@ void TritonRoute::sendGlobalsUpdates(const std::string& router_cfg_path,
918915 }
919916}
920917
921- void TritonRoute::sendDesignUpdates (const std::string& router_cfg_path,
922- int num_threads)
918+ void TritonRoute::sendDesignUpdates (const std::string& router_cfg_path)
923919{
924920 if (!distributed_) {
925921 return ;
@@ -934,7 +930,6 @@ void TritonRoute::sendDesignUpdates(const std::string& router_cfg_path,
934930 serializeTask = std::make_unique<ProfileTask>(" DIST: SERIALIZE_UPDATES" );
935931 }
936932 const auto & designUpdates = design_->getUpdates ();
937- omp_set_num_threads (num_threads);
938933 std::vector<std::string> updates (designUpdates.size ());
939934#pragma omp parallel for schedule(dynamic)
940935 for (int i = 0 ; i < designUpdates.size (); i++) {
@@ -970,15 +965,6 @@ void TritonRoute::sendDesignUpdates(const std::string& router_cfg_path,
970965
971966int TritonRoute::main ()
972967{
973- // Just to verify that OMP support is compiled in correctly.
974- omp_set_num_threads (2 );
975- #pragma omp parallel
976- {
977- if (omp_get_num_threads () != 2 ) {
978- logger_->error (DRT, 623 , " OMP threading is not working." );
979- }
980- }
981-
982968 if (router_cfg_->DBPROCESSNODE == " GF14_13M_3Mx_2Cx_4Kx_2Hx_2Gx_LB" ) {
983969 router_cfg_->USENONPREFTRACKS = false ;
984970 }
@@ -1061,8 +1047,7 @@ int TritonRoute::main()
10611047 prep ();
10621048 ta ();
10631049 if (distributed_) {
1064- asio::post (*dist_pool_,
1065- [this ] { sendDesignUpdates (" " , router_cfg_->MAX_THREADS ); });
1050+ asio::post (*dist_pool_, [this ] { sendDesignUpdates (" " ); });
10661051 }
10671052 dr ();
10681053 if (!router_cfg_->SINGLE_STEP_DR ) {
@@ -1120,12 +1105,11 @@ void TritonRoute::addInstancePAData(frInst* inst)
11201105 }
11211106}
11221107
1123- void TritonRoute::fixMaxSpacing (int num_threads )
1108+ void TritonRoute::fixMaxSpacing ()
11241109{
11251110 initDesign ();
11261111 initGuide ();
11271112 prep ();
1128- router_cfg_->MAX_THREADS = num_threads;
11291113 dr_ = std::make_unique<FlexDR>(
11301114 this , getDesign (), logger_, db_, router_cfg_.get ());
11311115 dr_->init ();
@@ -1173,7 +1157,6 @@ void TritonRoute::getDRCMarkers(frList<std::unique_ptr<frMarker>>& markers,
11731157 }
11741158 }
11751159 std::map<MarkerId, frMarker*> mapMarkers;
1176- omp_set_num_threads (router_cfg_->MAX_THREADS );
11771160 for (auto & workers : workersBatches) {
11781161#pragma omp parallel for schedule(dynamic)
11791162 for (int i = 0 ; i < workers.size (); i++) { // NOLINT
@@ -1206,12 +1189,10 @@ void TritonRoute::checkDRC(const char* filename,
12061189 int y1,
12071190 int x2,
12081191 int y2,
1209- const std::string& marker_name,
1210- int num_threads)
1192+ const std::string& marker_name)
12111193{
12121194 router_cfg_->GC_IGNORE_PDN_LAYER_NUM = -1 ;
12131195 router_cfg_->REPAIR_PDN_LAYER_NUM = -1 ;
1214- router_cfg_->MAX_THREADS = num_threads;
12151196 initDesign ();
12161197 auto gcellGrid = db_->getChip ()->getBlock ()->getGCellGrid ();
12171198 if (gcellGrid != nullptr && gcellGrid->getNumGridPatternsX () == 1
@@ -1300,7 +1281,6 @@ void TritonRoute::setParams(const ParamStruct& params)
13001281 }
13011282 router_cfg_->SAVE_GUIDE_UPDATES = params.saveGuideUpdates ;
13021283 router_cfg_->REPAIR_PDN_LAYER_NAME = params.repairPDNLayerName ;
1303- router_cfg_->MAX_THREADS = params.num_threads ;
13041284}
13051285
13061286void TritonRoute::addWorkerResults (
0 commit comments