- char category_type[INSTR_DEFAULT_STR_SIZE];
- snprintf (category_type, INSTR_DEFAULT_STR_SIZE, "b%s", category);
- XBT_DEBUG("CAT LINK [%f - %f] %s %s %f", now, now+delta, resource, category_type, value);
- container_t container = simgrid::instr::Container::byName(resource);
- simgrid::instr::Type* type = container->type_->byName(category_type);
- instr_event (now, delta, type, container, value);
+ std::string category_type = std::string("b") + category;
+ XBT_DEBUG("CAT LINK [%f - %f] %s %s %f", now, now + delta, resource, category_type.c_str(), value);
+ simgrid::instr::VariableType* variable = container->getVariable(category_type);
+ instr_event(now, delta, variable, container, value);