filter->insert(aux2);
//declare type
- std::string link_typename = father->type_->getName() + "-" + src->type_->getName() + src->type_->getId() + "-" +
- dst->type_->getName() + dst->type_->getId();
+ std::string link_typename = father->type_->getName() + "-" + src->type_->getName() +
+ std::to_string(src->type_->getId()) + "-" + dst->type_->getName() +
+ std::to_string(dst->type_->getId());
simgrid::instr::Type* link_type = father->type_->getOrCreateLinkType(link_typename, src->type_, dst->type_);
//register EDGE types for triva configuration
{
std::string id = netzone.getName();
- if (PJ_container_get_root() == nullptr){
+ if (simgrid::instr::Container::getRootContainer() == nullptr) {
simgrid::instr::NetZoneContainer* root = new simgrid::instr::NetZoneContainer(id, 0, nullptr);
if (TRACE_smpi_is_enabled()) {
container->type_->getOrCreateContainerType("MPI")->getOrCreateStateType("MPI_STATE");
if (TRACE_msg_process_is_enabled()) {
- simgrid::instr::Type* msg_process = container->type_->getOrCreateContainerType("MSG_PROCESS");
- simgrid::instr::Type* state = msg_process->getOrCreateStateType("MSG_PROCESS_STATE");
+ simgrid::instr::ContainerType* msg_process = container->type_->getOrCreateContainerType("MSG_PROCESS");
+ simgrid::instr::StateType* state = msg_process->getOrCreateStateType("MSG_PROCESS_STATE");
state->addEntityValue("suspend", "1 0 1");
state->addEntityValue("sleep", "1 1 0");
state->addEntityValue("receive", "1 0 0");
}
if (TRACE_msg_vm_is_enabled()) {
- simgrid::instr::Type* msg_vm = container->type_->getOrCreateContainerType("MSG_VM");
- simgrid::instr::Type* state = msg_vm->getOrCreateStateType("MSG_VM_STATE");
+ simgrid::instr::ContainerType* msg_vm = container->type_->getOrCreateContainerType("MSG_VM");
+ simgrid::instr::StateType* state = msg_vm->getOrCreateStateType("MSG_VM_STATE");
state->addEntityValue("suspend", "1 0 1");
state->addEntityValue("sleep", "1 1 0");
state->addEntityValue("receive", "1 0 0");
currentContainer.clear();
std::set<std::string>* filter = new std::set<std::string>;
XBT_DEBUG ("Starting graph extraction.");
- recursiveGraphExtraction(simgrid::s4u::Engine::getInstance()->getNetRoot(), PJ_container_get_root(), filter);
+ recursiveGraphExtraction(simgrid::s4u::Engine::getInstance()->getNetRoot(),
+ simgrid::instr::Container::getRootContainer(), filter);
XBT_DEBUG ("Graph extraction finished.");
delete filter;
platform_created = 1;
static void recursiveNewUserStateType(std::string father_type, std::string new_typename, simgrid::instr::Type* root)
{
- if (root->getName() == father_type) {
+ if (root->getName() == father_type)
root->getOrCreateStateType(new_typename);
- }
+
for (auto elm : root->children_)
recursiveNewUserStateType(father_type, new_typename, elm.second);
}
simgrid::instr::Type* root)
{
if (root->getName() == type_name)
- root->addEntityValue(val, color);
+ static_cast<simgrid::instr::StateType*>(root)->addEntityValue(val, color);
for (auto elm : root->children_)
recursiveNewValueForUserStateType(type_name, val, color, elm.second);
std::map<std::string, xbt_node_t>* nodes = new std::map<std::string, xbt_node_t>;
std::map<std::string, xbt_edge_t>* edges = new std::map<std::string, xbt_edge_t>;
recursiveXBTGraphExtraction(ret, nodes, edges, simgrid::s4u::Engine::getInstance()->getNetRoot(),
- PJ_container_get_root());
+ simgrid::instr::Container::getRootContainer());
delete nodes;
delete edges;
return ret;