Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
that example is useless too
authorMartin Quinson <martin.quinson@loria.fr>
Tue, 20 Mar 2012 16:36:06 +0000 (17:36 +0100)
committerMartin Quinson <martin.quinson@loria.fr>
Tue, 20 Mar 2012 16:36:06 +0000 (17:36 +0100)
examples/msg/parallel_contexts/CMakeLists.txt [deleted file]
examples/msg/parallel_contexts/deployment_pcontexts2_4.xml [deleted file]
examples/msg/parallel_contexts/deployment_pcontexts_2.xml [deleted file]
examples/msg/parallel_contexts/deployment_pcontexts_4.xml [deleted file]
examples/msg/parallel_contexts/pcontexts.c [deleted file]
examples/msg/parallel_contexts/pcontexts2.c [deleted file]
examples/msg/parallel_contexts/pcontexts_platform.xml [deleted file]

diff --git a/examples/msg/parallel_contexts/CMakeLists.txt b/examples/msg/parallel_contexts/CMakeLists.txt
deleted file mode 100644 (file)
index be6a21f..0000000
+++ /dev/null
@@ -1,15 +0,0 @@
-cmake_minimum_required(VERSION 2.6)
-
-set(EXECUTABLE_OUTPUT_PATH "${CMAKE_CURRENT_BINARY_DIR}")
-
-add_executable(pcontexts "pcontexts.c")
-add_executable(pcontexts2 "pcontexts2.c")
-
-### Add definitions for compile
-if(WIN32)
-target_link_libraries(pcontexts simgrid )
-target_link_libraries(pcontexts2 simgrid )
-else(WIN32)
-target_link_libraries(pcontexts simgrid m )
-target_link_libraries(pcontexts2 simgrid m )
-endif(WIN32)
diff --git a/examples/msg/parallel_contexts/deployment_pcontexts2_4.xml b/examples/msg/parallel_contexts/deployment_pcontexts2_4.xml
deleted file mode 100644 (file)
index fc6b97b..0000000
+++ /dev/null
@@ -1,16 +0,0 @@
-<?xml version='1.0'?>
-<!DOCTYPE platform SYSTEM "http://simgrid.gforge.inria.fr/simgrid.dtd">
-<platform version="3">
-  <process host="Tremblay" function="master">
-    <argument value="1" />
-  </process>
-  <process host="Jupiter" function="slave">
-    <argument value="1" />
-  </process>
-  <process host="Fafard" function="master">
-    <argument value="2" />
-  </process>
-  <process host="Ginette" function="slave">
-    <argument value="2" />
-  </process>
-</platform>
diff --git a/examples/msg/parallel_contexts/deployment_pcontexts_2.xml b/examples/msg/parallel_contexts/deployment_pcontexts_2.xml
deleted file mode 100644 (file)
index 61e4653..0000000
+++ /dev/null
@@ -1,8 +0,0 @@
-<?xml version='1.0'?>
-<!DOCTYPE platform SYSTEM "http://simgrid.gforge.inria.fr/simgrid.dtd">
-<platform version="3">
-  <process host="Tremblay" function="node">
-  </process>
-  <process host="Jupiter" function="node">
-  </process>
-</platform>
diff --git a/examples/msg/parallel_contexts/deployment_pcontexts_4.xml b/examples/msg/parallel_contexts/deployment_pcontexts_4.xml
deleted file mode 100644 (file)
index 3fc1233..0000000
+++ /dev/null
@@ -1,12 +0,0 @@
-<?xml version='1.0'?>
-<!DOCTYPE platform SYSTEM "http://simgrid.gforge.inria.fr/simgrid.dtd">
-<platform version="3">
-  <process host="Tremblay" function="node">
-  </process>
-  <process host="Jupiter" function="node">
-  </process>
-  <process host="Fafard" function="node">
-  </process>
-  <process host="Ginette" function="node">
-  </process>
-</platform>
diff --git a/examples/msg/parallel_contexts/pcontexts.c b/examples/msg/parallel_contexts/pcontexts.c
deleted file mode 100644 (file)
index 4cfbad9..0000000
+++ /dev/null
@@ -1,71 +0,0 @@
-#include <msg/msg.h>
-/* Create a log channel to have nice outputs. */
-#include "xbt/log.h"
-
-XBT_LOG_NEW_DEFAULT_CATEGORY(msg_test,
-                             "Messages specific for this msg example");
-#define MAX_ITER 200000
-#define WORK 100000
-
-int node(int argc, char **argv);
-MSG_error_t test_all(const char *, const char *);
-int main(int argc, char *argv[]);
-
-int node(int argc, char** argv)
-{
-  int i,j;
-  m_task_t task;
-
-  for(i=0; i < MAX_ITER; i++){
-    task = MSG_task_create("test", 100000000, 1, NULL);
-
-    for(j=0; j < WORK; j++);
-
-    MSG_task_execute(task);
-    XBT_INFO("Task successfully executed");
-    MSG_task_destroy(task);
-  }
-
-  return 0;
-}
-
-/** Test function */
-MSG_error_t test_all(const char *platform_file,
-                     const char *application_file)
-{
-  MSG_error_t res = MSG_OK;
-
-  /* MSG_config("workstation/model","KCCFLN05"); */
-  {                             /*  Simulation setting */
-    MSG_create_environment(platform_file);
-  }
-  {                             /*   Application deployment */
-    MSG_function_register("node", node);
-    MSG_launch_application(application_file);
-  }
-  res = MSG_main();
-
-  XBT_INFO("Simulation time %g", MSG_get_clock());
-  return res;
-}                               /* end_of_test_all */
-
-
-/** Main function */
-int main(int argc, char *argv[])
-{
-  MSG_error_t res = MSG_OK;
-
-  MSG_global_init(&argc, argv);
-  if (argc < 3) {
-    printf("Usage: %s platform_file deployment_file\n", argv[0]);
-    printf("example: %s msg_platform.xml msg_deployment.xml\n", argv[0]);
-    exit(1);
-  }
-  res = test_all(argv[1], argv[2]);
-  MSG_clean();
-
-  if (res == MSG_OK)
-    return 0;
-  else
-    return 1;
-}                               /* end_of_main */
diff --git a/examples/msg/parallel_contexts/pcontexts2.c b/examples/msg/parallel_contexts/pcontexts2.c
deleted file mode 100644 (file)
index fb469c9..0000000
+++ /dev/null
@@ -1,96 +0,0 @@
-#include <msg/msg.h>
-/* Create a log channel to have nice outputs. */
-#include "xbt/log.h"
-
-XBT_LOG_NEW_DEFAULT_CATEGORY(msg_test,
-                             "Messages specific for this msg example");
-#define MAX_ITER 200000
-#define WORK 100000
-
-int master(int argc, char **argv);
-int slave(int argc, char **argv);
-
-MSG_error_t test_all(const char *, const char *);
-int main(int argc, char *argv[]);
-
-int master(int argc, char** argv)
-{
-  int i,j, id;
-  m_task_t task;
-  char mailbox[80];
-
-  sscanf(argv[1], "%d", &id);
-  sprintf(mailbox, "slave-%d", id);
-
-  for(i=0; i < MAX_ITER; i++){
-    task = MSG_task_create("test", 100000000, 1, NULL);
-
-    for(j=0; j < WORK; j++);
-
-    MSG_task_send(task, mailbox);
-    XBT_INFO("Task sent to %s", mailbox);
-  }
-
-  return 0;
-}
-
-int slave(int argc, char **argv)
-{
-  int i, id;
-  m_task_t task;
-  char mailbox[80];
-
-  sscanf(argv[1], "%d", &id);
-  sprintf(mailbox, "slave-%d", id);
-
-  for(i=0; i < MAX_ITER; i++){
-    MSG_task_receive(&task, mailbox);
-    XBT_INFO("Task received to %s", mailbox);
-    MSG_task_destroy(task);
-    task=NULL;
-  }
-
-  return 0;
-}
-
-/** Test function */
-MSG_error_t test_all(const char *platform_file,
-                     const char *application_file)
-{
-  MSG_error_t res = MSG_OK;
-
-  /* MSG_config("workstation/model","KCCFLN05"); */
-  {                             /*  Simulation setting */
-    MSG_create_environment(platform_file);
-  }
-  {                             /*   Application deployment */
-    MSG_function_register("master", master);
-    MSG_function_register("slave", slave);
-    MSG_launch_application(application_file);
-  }
-  res = MSG_main();
-
-  XBT_INFO("Simulation time %g", MSG_get_clock());
-  return res;
-}                               /* end_of_test_all */
-
-
-/** Main function */
-int main(int argc, char *argv[])
-{
-  MSG_error_t res = MSG_OK;
-
-  MSG_global_init(&argc, argv);
-  if (argc < 3) {
-    printf("Usage: %s platform_file deployment_file\n", argv[0]);
-    printf("example: %s msg_platform.xml msg_deployment.xml\n", argv[0]);
-    exit(1);
-  }
-  res = test_all(argv[1], argv[2]);
-  MSG_clean();
-
-  if (res == MSG_OK)
-    return 0;
-  else
-    return 1;
-}                               /* end_of_main */
diff --git a/examples/msg/parallel_contexts/pcontexts_platform.xml b/examples/msg/parallel_contexts/pcontexts_platform.xml
deleted file mode 100644 (file)
index a990e32..0000000
+++ /dev/null
@@ -1,24 +0,0 @@
-<?xml version='1.0'?>
- <!DOCTYPE platform SYSTEM "http://simgrid.gforge.inria.fr/simgrid.dtd">
- <platform version="3">
- <AS  id="AS0"  routing="Full">
-   <!-- ljlkj -->
-   <host id="Tremblay" power="98095000"/>
-   <host id="Jupiter" power="98095000"/>
-   <host id="Fafard" power="98095000"/>
-   <host id="Ginette" power="98095000"/>
-   <link id="1" bandwidth="25275000" latency="0.00570455"/>
-   <link id="2" bandwidth="25275000" latency="0.00570455"/>
-   <link id="loopback" bandwidth="498000000" latency="0.000015" sharing_policy="FATPIPE"/>
-   <route src="Tremblay" dst="Tremblay"><link_ctn id="loopback"/></route>
-   <route src="Jupiter" dst="Jupiter"><link_ctn id="loopback"/></route>
-   <route src="Fafard" dst="Fafard"><link_ctn id="loopback"/></route>
-   <route src="Ginette" dst="Ginette"><link_ctn id="loopback"/></route>
-   <route src="Tremblay" dst="Jupiter">
-     <link_ctn id="1"/>
-   </route>
-   <route src="Fafard" dst="Ginette">
-     <link_ctn id="2"/>
-   </route>
- </AS>
- </platform>