Changeset 843 for XIOS/trunk/src/client_server_mapping_distributed.cpp
- Timestamp:
- 04/26/16 16:04:04 (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
XIOS/trunk/src/client_server_mapping_distributed.cpp
r835 r843 38 38 ccDHT_->computeIndexInfoMapping(globalIndexOnClient); 39 39 const boost::unordered_map<size_t,int>& infoIndexMap = (ccDHT_->getInfoIndexMap()); 40 boost::unordered_map<size_t,int>::const_iterator it = infoIndexMap.begin(), ite = infoIndexMap.end(); 41 for (; it != ite; ++it) 40 boost::unordered_map<size_t,int>::const_iterator itb = infoIndexMap.begin(), ite = infoIndexMap.end(), it; 41 std::vector<size_t> nbInfoIndex(ccDHT_->getNbClient(),0); 42 43 for (it = itb; it != ite; ++it) 42 44 { 43 indexGlobalOnServer_[it->second].push_back(it->first); 45 ++nbInfoIndex[it->second]; 46 } 47 48 for (int idx = 0; idx < nbInfoIndex.size(); ++idx) 49 { 50 if (0 != nbInfoIndex[idx]) 51 { 52 indexGlobalOnServer_[idx].resize(nbInfoIndex[idx]); 53 nbInfoIndex[idx] = 0; 54 } 55 } 56 57 for (it = itb; it != ite; ++it) 58 { 59 indexGlobalOnServer_[it->second][nbInfoIndex[it->second]] = (it->first); 60 ++nbInfoIndex[it->second]; 44 61 } 45 62 }
Note: See TracChangeset
for help on using the changeset viewer.