From c2c89401822ce6edf5d891533da3c77d633186ac Mon Sep 17 00:00:00 2001 From: Samuel Lepetit Date: Fri, 29 Jun 2012 11:45:17 +0200 Subject: [PATCH] Use msg_gpu_task_t instead of m_gpu_task_t --- examples/msg/gpu/test_MSG_gpu_task_create.c | 2 +- include/msg/datatypes.h | 7 ++++--- include/msg/msg.h | 2 +- src/msg/msg_task.c | 4 ++-- 4 files changed, 8 insertions(+), 7 deletions(-) diff --git a/examples/msg/gpu/test_MSG_gpu_task_create.c b/examples/msg/gpu/test_MSG_gpu_task_create.c index 9d176fd8b6..88109c99c9 100644 --- a/examples/msg/gpu/test_MSG_gpu_task_create.c +++ b/examples/msg/gpu/test_MSG_gpu_task_create.c @@ -26,7 +26,7 @@ int main(int argc, char *argv[]) MSG_init(&argc, argv); - m_gpu_task_t mytask = NULL; + msg_gpu_task_t mytask = NULL; mytask = MSG_gpu_task_create("testTask", 2000.0, 20.0, 20.0); diff --git a/include/msg/datatypes.h b/include/msg/datatypes.h index 8ca00d6c11..2a0a11fcf1 100644 --- a/include/msg/datatypes.h +++ b/include/msg/datatypes.h @@ -95,14 +95,14 @@ typedef s_file_stat_t s_msg_stat_t, *msg_stat_t; /*************** Begin GPU ***************/ typedef struct simdata_gpu_task *simdata_gpu_task_t; -typedef struct m_gpu_task { +typedef struct msg_gpu_task { char *name; /**< @brief task name if any */ simdata_gpu_task_t simdata; /**< @brief simulator data */ #ifdef HAVE_TRACING long long int counter; /* task unique identifier for instrumentation */ char *category; /* task category for instrumentation */ #endif -} s_m_gpu_task_t; +} s_msg_gpu_task_t; /** @brief GPU task datatype. @ingroup m_task_management @@ -111,7 +111,7 @@ typedef struct m_gpu_task { amount, a dispatch latency and a collect latency. \see m_task_management */ -typedef struct m_gpu_task *m_gpu_task_t; +typedef struct msg_gpu_task *msg_gpu_task_t; /*************** End GPU ***************/ /** @@ -145,6 +145,7 @@ typedef struct s_smx_process *msg_process_t; typedef msg_process_t m_process_t; typedef msg_host_t m_host_t; typedef msg_task_t m_task_t; +typedef msg_gpu_task_t m_gpu_task_t; #ifdef MSG_USE_DEPRECATED typedef int m_channel_t; diff --git a/include/msg/msg.h b/include/msg/msg.h index 314269d265..99888863ad 100644 --- a/include/msg/msg.h +++ b/include/msg/msg.h @@ -162,7 +162,7 @@ XBT_PUBLIC(void) MSG_process_auto_restart_set(msg_process_t process, int auto_re XBT_PUBLIC(msg_task_t) MSG_task_create(const char *name, double compute_duration, double message_size, void *data); -XBT_PUBLIC(m_gpu_task_t) MSG_gpu_task_create(const char *name, +XBT_PUBLIC(msg_gpu_task_t) MSG_gpu_task_create(const char *name, double compute_duration, double dispatch_latency, double collect_latency); diff --git a/src/msg/msg_task.c b/src/msg/msg_task.c index 74151b9940..7390b47623 100644 --- a/src/msg/msg_task.c +++ b/src/msg/msg_task.c @@ -139,10 +139,10 @@ MSG_parallel_task_create(const char *name, int host_nb, * \see m_gpu_task_t * \return The new corresponding object. */ -m_gpu_task_t MSG_gpu_task_create(const char *name, double compute_duration, +msg_gpu_task_t MSG_gpu_task_create(const char *name, double compute_duration, double dispatch_latency, double collect_latency) { - m_gpu_task_t task = xbt_new(s_m_gpu_task_t, 1); + msg_gpu_task_t task = xbt_new(s_msg_gpu_task_t, 1); simdata_gpu_task_t simdata = xbt_new(s_simdata_gpu_task_t, 1); task->simdata = simdata; /* Task structure */ -- 2.20.1