+/** \ingroup TRACE_user_variables
+ * \brief Add a value to the variable present in the links connecting source and destination.
+ *
+ * Same as #TRACE_link_variable_add, but instead of providing the
+ * name of link to be considered, provide the source and destination
+ * hosts. All links that are part of the route between source and
+ * destination will have the value passed as parameter added to
+ * the current value of the variable name to be considered.
+ *
+ * \param src The name of the source host for get route.
+ * \param dst The name of the destination host for get route.
+ * \param variable The name of the variable to be considered.
+ * \param value The value to be added to the variable.
+ *
+ * \see TRACE_link_variable_declare, TRACE_link_srcdst_variable_set, TRACE_link_srcdst_variable_sub
+ */
+void TRACE_link_srcdst_variable_add (const char *src, const char *dst, const char *variable, double value)
+{
+ TRACE_link_srcdst_variable_add_with_time (MSG_get_clock(), src, dst, variable, value);
+}
+
+/** \ingroup TRACE_user_variables
+ * \brief Subtract a value from the variable present in the links connecting source and destination.
+ *
+ * Same as #TRACE_link_variable_sub, but instead of providing the
+ * name of link to be considered, provide the source and destination
+ * hosts. All links that are part of the route between source and
+ * destination will have the value passed as parameter subtracted from
+ * the current value of the variable name to be considered.
+ *
+ * \param src The name of the source host for get route.
+ * \param dst The name of the destination host for get route.
+ * \param variable The name of the variable to be considered.
+ * \param value The value to be subtracted from the variable.
+ *
+ * \see TRACE_link_variable_declare, TRACE_link_srcdst_variable_set, TRACE_link_srcdst_variable_add
+ */
+void TRACE_link_srcdst_variable_sub (const char *src, const char *dst, const char *variable, double value)
+{
+ TRACE_link_srcdst_variable_sub_with_time (MSG_get_clock(), src, dst, variable, value);
+}
+
+/** \ingroup TRACE_user_variables
+ * \brief Set the value of the variable present in the links connecting source and destination at a given timestamp.
+ *
+ * Same as #TRACE_link_srcdst_variable_set, but let user specify
+ * the time used to trace it. Users can specify a time that
+ * is not the simulated clock time as defined by the core
+ * simulator. This allows a fine-grain control of time
+ * definition, but should be used with caution since the trace
+ * can be inconsistent if resource utilization traces are also traced.
+ *
+ * \param time The timestamp to be used to tag this change of value.
+ * \param src The name of the source host for get route.
+ * \param dst The name of the destination host for get route.
+ * \param variable The name of the variable to be considered.
+ * \param value The new value of the variable.
+ *
+ * \see TRACE_link_variable_declare, TRACE_link_srcdst_variable_add_with_time, TRACE_link_srcdst_variable_sub_with_time
+ */
+void TRACE_link_srcdst_variable_set_with_time (double time, const char *src, const char *dst, const char *variable, double value)
+{
+ instr_user_srcdst_variable (time, src, dst, variable, "LINK", value, INSTR_US_SET);
+}
+
+/** \ingroup TRACE_user_variables
+ * \brief Add a value to the variable present in the links connecting source and destination at a given timestamp.
+ *
+ * Same as #TRACE_link_srcdst_variable_add, but let user specify
+ * the time used to trace it. Users can specify a time that
+ * is not the simulated clock time as defined by the core
+ * simulator. This allows a fine-grain control of time
+ * definition, but should be used with caution since the trace
+ * can be inconsistent if resource utilization traces are also traced.
+ *
+ * \param time The timestamp to be used to tag this change of value.
+ * \param src The name of the source host for get route.
+ * \param dst The name of the destination host for get route.
+ * \param variable The name of the variable to be considered.
+ * \param value The value to be added to the variable.
+ *
+ * \see TRACE_link_variable_declare, TRACE_link_srcdst_variable_set_with_time, TRACE_link_srcdst_variable_sub_with_time
+ */
+void TRACE_link_srcdst_variable_add_with_time (double time, const char *src, const char *dst, const char *variable, double value)
+{
+ instr_user_srcdst_variable (time, src, dst, variable, "LINK", value, INSTR_US_ADD);
+}
+
+/** \ingroup TRACE_user_variables
+ * \brief Subtract a value from the variable present in the links connecting source and destination at a given timestamp.
+ *
+ * Same as #TRACE_link_srcdst_variable_sub, but let user specify
+ * the time used to trace it. Users can specify a time that
+ * is not the simulated clock time as defined by the core
+ * simulator. This allows a fine-grain control of time
+ * definition, but should be used with caution since the trace
+ * can be inconsistent if resource utilization traces are also traced.
+ *
+ * \param time The timestamp to be used to tag this change of value.
+ * \param src The name of the source host for get route.
+ * \param dst The name of the destination host for get route.
+ * \param variable The name of the variable to be considered.
+ * \param value The value to be subtracted from the variable.
+ *
+ * \see TRACE_link_variable_declare, TRACE_link_srcdst_variable_set_with_time, TRACE_link_srcdst_variable_add_with_time
+ */
+void TRACE_link_srcdst_variable_sub_with_time (double time, const char *src, const char *dst, const char *variable, double value)
+{
+ instr_user_srcdst_variable (time, src, dst, variable, "LINK", value, INSTR_US_SUB);
+}
+
+/** \ingroup TRACE_user_variables
+ * \brief Get declared user link variables
+ *
+ * This function should be used to get link variables that were already
+ * declared with #TRACE_link_variable_declare or with #TRACE_link_variable_declare_with_color.
+ *
+ * \return A dynar with the declared link variables, must be freed with xbt_dynar_free.
+ */
+xbt_dynar_t TRACE_get_link_variables (void)