1 /* Copyright (c) 2004, 2005, 2007, 2008, 2009, 2010. The SimGrid Team.
2 * All rights reserved. */
4 /* This program is free software; you can redistribute it and/or modify it
5 * under the terms of the license (GNU LGPL) which comes with this package. */
10 #include "xbt/file_stat.h"
11 #include "simgrid_config.h" // for HAVE_TRACING
15 /* ******************************** Host ************************************ */
17 typedef struct simdata_host *simdata_host_t;
19 typedef struct m_host {
20 char *name; /**< @brief host name if any */
21 simdata_host_t simdata; /**< @brief simulator data */
22 void *data; /**< @brief user data */
25 /** @brief Host datatype
26 @ingroup m_host_management
28 A <em>location</em> (or <em>host</em>) is any possible place where
29 a process may run. Thus it is represented as a <em>physical
30 resource with computing capabilities</em>, some <em>mailboxes</em>
31 to enable running process to communicate with remote ones, and
32 some <em>private data</em> that can be only accessed by local
35 typedef struct m_host *m_host_t;
37 /* ******************************** Task ************************************ */
39 typedef struct simdata_task *simdata_task_t;
41 typedef struct m_task {
42 char *name; /**< @brief task name if any */
43 simdata_task_t simdata; /**< @brief simulator data */
44 void *data; /**< @brief user data */
46 long long int counter; /* task unique identifier for instrumentation */
47 char *category; /* task category for instrumentation */
51 /** @brief Task datatype
52 @ingroup m_task_management
54 A <em>task</em> may then be defined by a <em>computing
55 amount</em>, a <em>message size</em> and some <em>private
58 typedef struct m_task *m_task_t;
61 /* ******************************** File ************************************ */
62 typedef struct simdata_file *simdata_file_t;
64 typedef struct msg_file {
65 char *name; /**< @brief file name */
66 simdata_file_t simdata; /**< @brief simulator data */
67 void *data; /**< @brief user data */
70 /** @brief File datatype.
71 @ingroup msg_file_management
73 You should consider this as an opaque object.
75 typedef struct msg_file *msg_file_t;
77 typedef s_file_stat_t s_msg_stat_t, *msg_stat_t;
80 /*************** Begin GPU ***************/
81 typedef struct simdata_gpu_task *simdata_gpu_task_t;
83 typedef struct m_gpu_task {
84 char *name; /**< @brief task name if any */
85 simdata_gpu_task_t simdata; /**< @brief simulator data */
87 long long int counter; /* task unique identifier for instrumentation */
88 char *category; /* task category for instrumentation */
92 /** @brief GPU task datatype
93 @ingroup m_task_management
95 A <em>task</em> may then be defined by a <em>computing
96 amount</em>, a <em>dispatch latency</em> and a <em>collect latency</em>.
97 \see m_task_management
99 typedef struct m_gpu_task *m_gpu_task_t;
100 /*************** End GPU ***************/
103 * \brief @brief Communication action.
104 * \ingroup m_datatypes_management
106 * Communication actions transfer tasks between processes.
107 * For a given task, the sender and the receiver have distinct objects.
109 typedef struct msg_comm *msg_comm_t;
111 /** \brief Default value for an uninitialized #m_task_t.
112 \ingroup m_task_management
114 #define MSG_TASK_UNINITIALIZED NULL
116 /* ****************************** Process *********************************** */
118 /** @brief Process datatype.
119 @ingroup m_process_management
121 A process may be defined as a <em>code</em>, with some
122 <em>private data</em>, executing in a <em>location</em>.
124 You should not access directly to the fields of the pointed
125 structure, but always use the provided API to interact with
128 typedef struct s_smx_process *m_process_t;
130 #ifdef MSG_USE_DEPRECATED
131 typedef int m_channel_t;
134 /* ******************************** Mailbox ************************************ */
136 /** @brief Mailbox datatype
137 @ingroup m_datatypes_management
139 typedef struct s_smx_rvpoint *msg_mailbox_t;