----------------------------------------------------------------------
| 763 | |
| 764 | // ---------------------------------------------------------------------- |
| 765 | void CommProfStats::ReportSyncPointDataSetup(long &nBMax, long &nRMax) |
| 766 | { |
| 767 | Vector<long> nBarriers(dataNProcs, 0L); |
| 768 | Vector<long> nReductions(dataNProcs, 0L); |
| 769 | for(int idb(0); idb < dataBlocks.size(); ++idb) { |
| 770 | DataBlock &dBlock = dataBlocks[idb]; |
| 771 | int proc(dBlock.proc); |
| 772 | |
| 773 | for(int idbb(0); idbb < dBlock.barriers.size(); ++idbb) { |
| 774 | BarrierEntry &be = dBlock.barriers[idbb]; |
| 775 | nBarriers[proc] = std::max(nBarriers[proc], be.number); |
| 776 | } |
| 777 | for(int idbb(0); idbb < dBlock.reductions.size(); ++idbb) { |
| 778 | ReductionEntry &re = dBlock.reductions[idbb]; |
| 779 | nReductions[proc] = std::max(nReductions[proc], re.number); |
| 780 | } |
| 781 | } |
| 782 | //nBMin = *std::min_element(nBarriers.begin(), nBarriers.end()); |
| 783 | nBMax = *std::ranges::max_element(nBarriers); |
| 784 | //nRMin = *std::min_element(nReductions.begin(), nReductions.end()); |
| 785 | nRMax = *std::ranges::max_element(nReductions); |
| 786 | } |
| 787 | |
| 788 | |
| 789 | // ---------------------------------------------------------------------- |