Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Rework the MSG navbar
[simgrid.git] / src / msg / task.c
index c353d75..84d6f90 100644 (file)
@@ -8,13 +8,12 @@
 #include "private.h"
 #include "xbt/sysdep.h"
 #include "xbt/log.h"
-XBT_LOG_NEW_DEFAULT_SUBCATEGORY(task, msg,
-                               "Logging specific to MSG (task)");
 
 /** \defgroup m_task_management Managing functions of Tasks
  *  \brief This section describes the task structure of MSG
  *  (#m_task_t) and the functions for managing it.
- *
+ *    \htmlonly <!-- DOXYGEN_NAVBAR_LABEL="Tasks" --> \endhtmlonly
+ * 
  *  Since most scheduling algorithms rely on a concept of task
  *  that can be either <em>computed</em> locally or
  *  <em>transferred</em> on another processor, it seems to be the
@@ -90,6 +89,17 @@ m_process_t MSG_task_get_sender(m_task_t task)
    return ((simdata_task_t) task->simdata)->sender;
 }
 
+/** \ingroup m_task_management
+ * \brief Return the source of a #m_task_t.
+ *
+ * This functions returns the #m_host_t from which this task was sent
+ */
+m_host_t MSG_task_get_source(m_task_t task)
+{
+   xbt_assert0(task, "Invalid parameters");
+   return ((simdata_task_t) task->simdata)->source;
+}
+
 /** \ingroup m_task_management
  * \brief Return the name of a #m_task_t.
  *