- return comm ? MSG_process_get_PID(static_cast<msg_task_t>(comm->src_buff_)->simdata->sender) : -1;
-}
-
-/**
- * @brief Sets the tracing category of a task.
- *
- * This function should be called after the creation of a MSG task, to define the category of that task. The
- * first parameter task must contain a task that was created with the function #MSG_task_create. The second
- * parameter category must contain a category that was previously declared with the function #TRACE_category
- * (or with #TRACE_category_with_color).
- *
- * See @ref outcomes_vizu for details on how to trace the (categorized) resource utilization.
- *
- * @param task the task that is going to be categorized
- * @param category the name of the category to be associated to the task
- *
- * @see MSG_task_get_category, TRACE_category, TRACE_category_with_color
- */
-void MSG_task_set_category (msg_task_t task, const char *category)
-{
- xbt_assert(not task->simdata->has_tracing_category(), "Task %p(%s) already has a category (%s).", task,
- task->simdata->get_cname(), task->simdata->get_tracing_category().c_str());
-
- // if user provides a nullptr category, task is no longer traced
- if (category == nullptr) {
- task->simdata->set_tracing_category("");
- XBT_DEBUG("MSG task %p(%s), category removed", task, task->simdata->get_cname());
- } else {
- // set task category
- task->simdata->set_tracing_category(category);
- XBT_DEBUG("MSG task %p(%s), category %s", task, task->simdata->get_cname(),
- task->simdata->get_tracing_category().c_str());
- }