std::vector<simgrid::kernel::routing::DragonflyZone*> dragonfly_clusters =
e.get_filtered_netzones<simgrid::kernel::routing::DragonflyZone>();
- if (not dragonfly_clusters.empty()) {
- for (auto d : dragonfly_clusters) {
- XBT_INFO("%s' dragonfly topology:", d->get_cname());
- for (int i = 0; i < d->get_host_count(); i++) {
- const simgrid::kernel::routing::DragonflyZone::Coords coords = d->rankId_to_coords(i);
- XBT_INFO(" %d: (%u, %u, %u, %u)", i, coords.group, coords.chassis, coords.blade, coords.node);
- }
+ for (auto d : dragonfly_clusters) {
+ XBT_INFO("%s' dragonfly topology:", d->get_cname());
+ for (int i = 0; i < d->get_host_count(); i++) {
+ const simgrid::kernel::routing::DragonflyZone::Coords coords = d->rankId_to_coords(i);
+ XBT_INFO(" %d: (%u, %u, %u, %u)", i, coords.group, coords.chassis, coords.blade, coords.node);
}
}
return;
}
XBT_DEBUG("Graph extraction for NetZone = %s", netzone->get_cname());
- if (not netzone->get_children().empty()) {
- // bottom-up recursion
- for (auto const& nz_son : netzone->get_children()) {
- simgrid::instr::Container* child_container = container->children_.at(nz_son->get_name());
- recursiveGraphExtraction(nz_son, child_container, filter);
- }
+
+ // bottom-up recursion
+ for (auto const& nz_son : netzone->get_children()) {
+ simgrid::instr::Container* child_container = container->children_.at(nz_son->get_name());
+ recursiveGraphExtraction(nz_son, child_container, filter);
}
auto* graph = xbt_graph_new_graph(0, nullptr);
boost::split(dimensions_str, topo_parameters, boost::is_any_of(","));
std::vector<unsigned int> dimensions;
- if (not dimensions_str.empty()) {
- /* We are in a torus cluster
- * Parse attribute dimensions="dim1,dim2,dim3,...,dimN" and save them into a vector.
- * Additionally, we need to know how many ranks we have in total
- */
- std::transform(begin(dimensions_str), end(dimensions_str), std::back_inserter(dimensions),
- [](const std::string& s) { return std::stoi(s); });
- }
+ /* We are in a torus cluster
+ * Parse attribute dimensions="dim1,dim2,dim3,...,dimN" and save them into a vector.
+ * Additionally, we need to know how many ranks we have in total
+ */
+ std::transform(begin(dimensions_str), end(dimensions_str), std::back_inserter(dimensions),
+ [](const std::string& s) { return std::stoi(s); });
+
return dimensions;
}
}
}
- if (not accumulates.empty()) {
- std::sort(accumulates.begin(), accumulates.end(), sort_accumulates);
- for (auto& req : accumulates) {
- finish_wait(&req, status);
- }
- }
+ std::sort(accumulates.begin(), accumulates.end(), sort_accumulates);
+ for (auto& req : accumulates)
+ finish_wait(&req, status);
return retvalue;
}