From: Frederic Suter Date: Mon, 18 Apr 2016 08:32:31 +0000 (+0200) Subject: end of MSG examples doc revision X-Git-Tag: v3_13~80 X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/commitdiff_plain/756b82fad06ba482ed401f3ed35c31874f367e8a?ds=sidebyside end of MSG examples doc revision + back to 3.12 "quality" + should be completed with other modules (cloud, energy, ...) --- diff --git a/doc/Doxyfile.in b/doc/Doxyfile.in index cc536f59d4..832f055823 100644 --- a/doc/Doxyfile.in +++ b/doc/Doxyfile.in @@ -716,13 +716,13 @@ INPUT += @CMAKE_HOME_DIRECTORY@/examples/msg/app-pingpong/app-pi @CMAKE_HOME_DIRECTORY@/examples/msg/network-ns3/network-ns3.c \ @CMAKE_HOME_DIRECTORY@/examples/msg/io-storage/io-storage.c \ @CMAKE_HOME_DIRECTORY@/examples/msg/io-file/io-file.c \ - @CMAKE_HOME_DIRECTORY@/examples/msg/io-file/io-remote.c \ - @CMAKE_HOME_DIRECTORY@/examples/msg/actions \ - @CMAKE_HOME_DIRECTORY@/examples/msg/pmm \ - @CMAKE_HOME_DIRECTORY@/examples/msg/chord\ + @CMAKE_HOME_DIRECTORY@/examples/msg/io-remote/io-remote.c \ + @CMAKE_HOME_DIRECTORY@/examples/msg/actions-comm/actions-comm.c \ + @CMAKE_HOME_DIRECTORY@/examples/msg/actions-storage/actions-storage.c \ + @CMAKE_HOME_DIRECTORY@/examples/msg/app-pmm/ \ + @CMAKE_HOME_DIRECTORY@/examples/msg/dht-chord \ @CMAKE_HOME_DIRECTORY@/examples/msg/task-priority/task-priority.c \ - @CMAKE_HOME_DIRECTORY@/examples/msg/properties \ - @CMAKE_HOME_DIRECTORY@/examples/msg/parallel_task + @CMAKE_HOME_DIRECTORY@/examples/msg/properties/properties.c # This tag can be used to specify the character encoding of the source files # that doxygen parses. Internally doxygen uses the UTF-8 encoding, which is diff --git a/doc/doxygen/module-msg.doc b/doc/doxygen/module-msg.doc index 88bda8e631..eb7312ffd1 100644 --- a/doc/doxygen/module-msg.doc +++ b/doc/doxygen/module-msg.doc @@ -160,10 +160,20 @@ Check the examples in examples/msg/actions/actions.c for details. @ingroup MSG_API @brief . -Finding the right example in examples/msg is sometimes difficult. This list aims at helping you to find the example from which you can learn what you want to. - -\section msg_bsc_ex Basic examples +Finding the right example in examples/msg is sometimes difficult. This list aims at helping you to find the example from which you can learn what you want to. + - @ref msg_ex_basic + - @ref msg_ex_async + - @ref msg_ex_process + - @ref msg_ex_tracing + - @ref msg_ex_tracing_user_variables + - @ref msg_ex_models + - @ref msg_ex_io + - @ref msg_ex_actions + - @ref msg_ex_full_apps + - @ref msg_ex_misc + +\section msg_ex_basic Basic examples */ diff --git a/examples/msg/actions-comm/actions-comm.c b/examples/msg/actions-comm/actions-comm.c index a67fabd30e..da5e79f0a8 100644 --- a/examples/msg/actions-comm/actions-comm.c +++ b/examples/msg/actions-comm/actions-comm.c @@ -10,21 +10,20 @@ /** @addtogroup MSG_examples * - * @section MSG_ex_actions Trace driven simulations + * @section msg_ex_actions Trace driven simulations * - * The actions/actions.c example demonstrates how to run trace-driven simulations. It is very handy when you - * want to test an algorithm or protocol that does nothing unless it receives some events from outside. For example, - * a P2P protocol reacts to requests from the user, but does nothing if there is no such event. + * This section details how to run trace-driven simulations. It is very handy when you want to test an algorithm or + * protocol that does nothing unless it receives some events from outside. For example, a P2P protocol reacts to + * requests from the user, but does nothing if there is no such event. * - * In such situations, SimGrid allows to write your protocol in your C file, and the events to react to in a separate + * In such situations, SimGrid allows you to write your protocol in a C file, and the events to react to in a separate * text file. Declare a function handling each of the events that you want to accept in your trace files, register * them using \ref xbt_replay_action_register in your main, and then use \ref MSG_action_trace_run to launch the * simulation. You can either have one trace file containing all your events, or a file per simulated process. Check - * the tesh files in the example directory for details on how to do it. + * the tesh files in the example directories for details on how to do it. * - * This example uses this approach to replay MPI-like traces. It comes with a set of event handlers reproducing MPI - * events. This is somehow similar to SMPI, yet differently implemented. This code should probably be changed to use - * SMPI internals instead, but wasn't, so far. + * - Communication: actions-comm/actions-comm.c. This example comes with a set of event handlers reproducing + * some classical communication primitives (synchronous and asynchronous send/receive, broadcast, barrier, ...). */ XBT_LOG_NEW_DEFAULT_CATEGORY(actions, "Messages specific for this msg example"); diff --git a/examples/msg/actions-storage/actions-storage.c b/examples/msg/actions-storage/actions-storage.c index 0d29d49857..4165f23eaf 100644 --- a/examples/msg/actions-storage/actions-storage.c +++ b/examples/msg/actions-storage/actions-storage.c @@ -8,6 +8,11 @@ #include XBT_LOG_NEW_DEFAULT_CATEGORY(storage_actions, "Messages specific for this example"); +/** @addtogroup MSG_examples + * + * - I/O: actions-comm/actions-comm.c. This example comes with a set of event handlers reproducing + * some classical I/O primitives (open, read, write, close, ...). + */ static xbt_dict_t opened_files = NULL; diff --git a/examples/msg/app-pmm/app-pmm.c b/examples/msg/app-pmm/app-pmm.c index 486584bd34..f55f1a2c60 100644 --- a/examples/msg/app-pmm/app-pmm.c +++ b/examples/msg/app-pmm/app-pmm.c @@ -11,10 +11,10 @@ #include "xbt/xbt_os_time.h" /** @addtogroup MSG_examples - * @section MSG_ex_apps Examples of full applications + * @section msg_ex_full_apps Examples of full applications * - * - pmm/msg_pmm.c: Parallel Matrix Multiplication is a little application. This is something that most MPI - * developers have written during their class, here implemented using MSG instead of MPI. + * - Parallel Matrix Multiplication: app-pmm/app-pmm.c. This little application is something that most MPI + * developers have written during their studies. Here it is implemented in MSG. */ XBT_LOG_NEW_DEFAULT_CATEGORY(msg_pmm, "Messages specific for this msg example"); diff --git a/examples/msg/async-wait/async-wait.c b/examples/msg/async-wait/async-wait.c index 1071d85353..49e06eac49 100644 --- a/examples/msg/async-wait/async-wait.c +++ b/examples/msg/async-wait/async-wait.c @@ -10,7 +10,7 @@ XBT_LOG_NEW_DEFAULT_CATEGORY(msg_async_wait, "Messages specific for this msg exa /** @addtogroup MSG_examples * - * @section MSG_ex_icomms Asynchronous communications + * @section msg_ex_async Asynchronous communications * * In addition to the fully documented example of \ref MSG_ex_asynchronous_communications, there are several othe * examples shipped in the archive: diff --git a/examples/msg/dht-chord/dht-chord.c b/examples/msg/dht-chord/dht-chord.c index 800a648bcf..976fa83397 100644 --- a/examples/msg/dht-chord/dht-chord.c +++ b/examples/msg/dht-chord/dht-chord.c @@ -11,10 +11,9 @@ /** @addtogroup MSG_examples * - * - chord/chord.c: Classical Chord P2P protocol - * This example implements the well known Chord P2P protocol. Its main advantage is that it constitute a fully - * working non-trivial example. In addition, its implementation is rather efficient, as demonstrated in - * http://hal.inria.fr/inria-00602216/ + * - Chord P2P protocol dht-chord/dht-chord.c:. This example implements the well known Chord P2P protocol. Its + * main advantage is that it constitutes a fully working non-trivial example. In addition, its implementation is + * rather efficient, as demonstrated in http://hal.inria.fr/inria-00602216/ */ diff --git a/examples/msg/io-remote/io-remote.c b/examples/msg/io-remote/io-remote.c index 86fd255ca0..1e8f7d6d18 100644 --- a/examples/msg/io-remote/io-remote.c +++ b/examples/msg/io-remote/io-remote.c @@ -6,7 +6,7 @@ /** @addtogroup MSG_examples * - * - Remote I/O: io-remote/io-remote.c I/O operation can also be done in a remote, which is illustrated here. + * - Remote I/O: io-remote/io-remote.c. I/O operations can also be done in a remote, which is illustrated here. */ #include "simgrid/msg.h" diff --git a/examples/msg/io-storage/io-storage.c b/examples/msg/io-storage/io-storage.c index f647c5a30b..f06bf84228 100644 --- a/examples/msg/io-storage/io-storage.c +++ b/examples/msg/io-storage/io-storage.c @@ -6,7 +6,7 @@ /** @addtogroup MSG_examples * - * @section MSG_ex_resources Simulation disks and files + * @section msg_ex_io Simulation disks and files * * This section lists some examples of storage simulation. This part of SimGrid is still preliminary. * diff --git a/examples/msg/network-ns3/network-ns3.c b/examples/msg/network-ns3/network-ns3.c index 74ae8bbede..66ff05ba8c 100644 --- a/examples/msg/network-ns3/network-ns3.c +++ b/examples/msg/network-ns3/network-ns3.c @@ -10,7 +10,7 @@ XBT_LOG_NEW_DEFAULT_CATEGORY(msg_test, "Messages specific for this msg example") /** @addtogroup MSG_examples * - * @section MSG_ex_models Models-related examples + * @section msg_ex_models Models-related examples * * @subsection MSG_ex_PLS Packet level simulators * diff --git a/examples/msg/process-suspend/process-suspend.c b/examples/msg/process-suspend/process-suspend.c index cdafaf106c..07e38fa29d 100644 --- a/examples/msg/process-suspend/process-suspend.c +++ b/examples/msg/process-suspend/process-suspend.c @@ -13,7 +13,7 @@ XBT_LOG_NEW_DEFAULT_CATEGORY(msg_process_suspend, "Messages specific for this ms xbt_die("What's going on??? I failed to sleep!"); /** @addtogroup MSG_examples - * @section MSG_ex_process Acting on Processes + * @section msg_ex_process Acting on Processes * * - Suspend/Resume: process-suspend/process-suspend.c. Processes can be suspended and resumed during * their executions thanks to the @ref MSG_process_suspend and @ref MSG_process_resume functions. diff --git a/examples/msg/properties/properties.c b/examples/msg/properties/properties.c index caae47f822..178de370e7 100644 --- a/examples/msg/properties/properties.c +++ b/examples/msg/properties/properties.c @@ -8,10 +8,10 @@ /** @addtogroup MSG_examples * - * - properties/msg_prop.c Attaching arbitrary informations to host, processes and such, and retrieving them - * with @ref MSG_host_get_properties, @ref MSG_host_get_property_value, @ref MSG_process_get_properties and - * @ref MSG_process_get_property_value. Also make sure to read the platform and deployment XML files to see how to - * declare these data. + * - User-defined properties: properties/properties.c Attaching arbitrary informations to host, processes and + * such, and retrieving them with @ref MSG_host_get_properties, @ref MSG_host_get_property_value, + * @ref MSG_process_get_properties, and @ref MSG_process_get_property_value. Also make sure to read the platform and + * deployment XML files to see how to declare these data. */ XBT_LOG_NEW_DEFAULT_CATEGORY(test, "Property test"); diff --git a/examples/msg/task-priority/task-priority.c b/examples/msg/task-priority/task-priority.c index 37f477bea4..cb463b712a 100644 --- a/examples/msg/task-priority/task-priority.c +++ b/examples/msg/task-priority/task-priority.c @@ -9,8 +9,9 @@ XBT_LOG_NEW_DEFAULT_CATEGORY(msg_test, "Messages specific for this msg example") /** @addtogroup MSG_examples * - * - priority/priority.c: Demonstrates the use of @ref - * MSG_task_set_priority to change the computation priority of a given task. + * @section msg_ex_misc Miscellaneous + * - Task priorities: task-priority/task-priority.c. This examples demonstrates the use of + * @ref MSG_task_set_priority to change the computation priority of a given task. */ static int test(int argc, char *argv[]) diff --git a/examples/msg/trace-simple/trace-simple.c b/examples/msg/trace-simple/trace-simple.c index 20b1395c30..b735435f84 100644 --- a/examples/msg/trace-simple/trace-simple.c +++ b/examples/msg/trace-simple/trace-simple.c @@ -8,7 +8,7 @@ /** @addtogroup MSG_examples * - * @section MSG_ex_tracing Tracing and visualization features + * @section msg_ex_tracing Tracing and visualization features * Tracing can be activated by various configuration options which are illustrated in these example. * See \ref tracing_tracing_options for details. * - Basic example: trace-simple/trace-simple.c. In this very simple program, each process creates, executes, diff --git a/examples/msg/trace-user-variables/trace-user-variables.c b/examples/msg/trace-user-variables/trace-user-variables.c index 31b32a60c3..aef88a6f59 100644 --- a/examples/msg/trace-user-variables/trace-user-variables.c +++ b/examples/msg/trace-user-variables/trace-user-variables.c @@ -6,7 +6,7 @@ /** @addtogroup MSG_examples * - * @section MSG_ex_tracing_user_variables Tracing user variables + * @section msg_ex_tracing_user_variables Tracing user variables * The tracing mechanism of SimGrid also allows to associate user variables to resources described in the platform file. * The following examples illustrate this feature. They have to be run with the --cfg=tracing:yes and * --cfg=tracing/platform:yes options.