Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Remove an obsolete example
authorMartin Quinson <martin.quinson@ens-rennes.fr>
Thu, 23 Dec 2021 15:49:57 +0000 (16:49 +0100)
committerMartin Quinson <martin.quinson@ens-rennes.fr>
Thu, 23 Dec 2021 16:07:49 +0000 (17:07 +0100)
MANIFEST.in
teshsuite/simdag/CMakeLists.txt
teshsuite/simdag/availability/availability.c [deleted file]
teshsuite/simdag/availability/availability.tesh [deleted file]

index c0d0687..8e7a161 100644 (file)
@@ -819,8 +819,6 @@ include teshsuite/s4u/wait-all-for/wait-all-for.cpp
 include teshsuite/s4u/wait-all-for/wait-all-for.tesh
 include teshsuite/s4u/wait-any-for/wait-any-for.cpp
 include teshsuite/s4u/wait-any-for/wait-any-for.tesh
-include teshsuite/simdag/availability/availability.c
-include teshsuite/simdag/availability/availability.tesh
 include teshsuite/simdag/flatifier/bogus_missing_gateway.tesh
 include teshsuite/simdag/flatifier/bogus_two_hosts_asymetric.tesh
 include teshsuite/simdag/flatifier/flatifier.cpp
index d51c9fd..020ab62 100644 (file)
@@ -1,13 +1,3 @@
-foreach(x availability )
-  add_executable       (${x}  EXCLUDE_FROM_ALL ${x}/${x}.c)
-  target_link_libraries(${x}  simgrid)
-  set_target_properties(${x}  PROPERTIES RUNTIME_OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/${x})
-  add_dependencies(tests ${x})
-
-  set(tesh_files    ${tesh_files}    ${CMAKE_CURRENT_SOURCE_DIR}/${x}/${x}.tesh)
-  set(teshsuite_src ${teshsuite_src} ${CMAKE_CURRENT_SOURCE_DIR}/${x}/${x}.c)
-endforeach()
-
 foreach(x flatifier)
   add_executable       (${x} EXCLUDE_FROM_ALL ${x}/${x}.cpp)
   target_link_libraries(${x}  simgrid)
@@ -53,7 +43,7 @@ set(txt_files     ${txt_files}      ${CMAKE_CURRENT_SOURCE_DIR}/platforms/carol.
                                     ${CMAKE_CURRENT_SOURCE_DIR}/platforms/link.fail
                                     ${CMAKE_CURRENT_SOURCE_DIR}/platforms/link.lat                         PARENT_SCOPE)
 
-foreach(x availability flatifier)
+foreach(x flatifier)
   ADD_TESH(tesh-simdag-${x} --setenv bindir=${CMAKE_BINARY_DIR}/teshsuite/simdag/${x} --setenv srcdir=${CMAKE_HOME_DIRECTORY} --cd ${CMAKE_HOME_DIRECTORY}/teshsuite/simdag/${x} ${x}.tesh)
 endforeach()
 
diff --git a/teshsuite/simdag/availability/availability.c b/teshsuite/simdag/availability/availability.c
deleted file mode 100644 (file)
index 13ec72f..0000000
+++ /dev/null
@@ -1,64 +0,0 @@
-/* Copyright (c) 2013-2021. The SimGrid Team.
- * All rights reserved.                                                     */
-
-/* This program is free software; you can redistribute it and/or modify it
- * under the terms of the license (GNU LGPL) which comes with this package. */
-
-#include <string.h>
-#include <simgrid/simdag.h>
-#include <xbt/log.h>
-
-XBT_LOG_NEW_DEFAULT_CATEGORY(test,"Logging for the current example");
-
-static int name_compare_hosts(const void *n1, const void *n2)
-{
-  return strcmp(sg_host_get_name(*(const sg_host_t*)n1), sg_host_get_name(*(const sg_host_t*)n2));
-}
-
-static void scheduleDAX(const_xbt_dynar_t dax)
-{
-  unsigned int cursor;
-  SD_task_t task;
-
-  sg_host_t *hosts = sg_host_list();
-  size_t totalHosts = sg_host_count();
-  qsort(hosts, totalHosts, sizeof(sg_host_t), name_compare_hosts);
-
-  xbt_dynar_foreach(dax, cursor, task) {
-    if (SD_task_get_kind(task) == SD_TASK_COMP_SEQ) {
-      if (!strcmp(SD_task_get_name(task), "end") || !strcmp(SD_task_get_name(task), "root")) {
-        XBT_INFO("Scheduling %s to node: %s", SD_task_get_name(task), sg_host_get_name(hosts[0]));
-        SD_task_schedulel(task, 1, hosts[0]);
-      } else {
-        XBT_INFO("Scheduling %s to node: %s", SD_task_get_name(task), sg_host_get_name(hosts[(cursor) % totalHosts]));
-        SD_task_schedulel(task, 1, hosts[cursor % totalHosts]);
-      }
-    }
-  }
-  xbt_free(hosts);
-}
-
-int main(int argc, char *argv[])
-{
-  SD_init(&argc, argv);
-  xbt_assert(argc > 2, "Usage: %s platform_file dax_file\n"
-             "\tExample: %s simulacrum_7_hosts.xml Montage_25.xml", argv[0], argv[0]);
-
-  SD_create_environment(argv[1]);
-  xbt_dynar_t dax = SD_daxload(argv[2]);
-
-  XBT_INFO("Scheduling DAX...");
-  scheduleDAX(dax);
-  XBT_INFO("DAX scheduled");
-  SD_simulate(-1);
-
-  XBT_INFO("Simulation done.");
-
-  // Free memory
-  while (!xbt_dynar_is_empty(dax)) {
-    SD_task_t task = xbt_dynar_pop_as(dax, SD_task_t);
-    SD_task_destroy(task);
-  }
-  xbt_dynar_free(&dax);
-  return 0;
-}
diff --git a/teshsuite/simdag/availability/availability.tesh b/teshsuite/simdag/availability/availability.tesh
deleted file mode 100644 (file)
index 2eb81f7..0000000
+++ /dev/null
@@ -1,33 +0,0 @@
-$ ${bindir:=.}/availability ../../../examples/platforms/simulacrum_7_hosts.xml  ../../../examples/deprecated/simdag/scheduling/Montage_25.xml --log=sd_daxparse.thresh:critical
-> [0.000000] [xbt_cfg/INFO] Switching to the L07 model to handle parallel tasks.
-> [0.000000] [test/INFO] Scheduling DAX...
-> [0.000000] [test/INFO] Scheduling root to node: Host 26
-> [0.000000] [test/INFO] Scheduling ID00000@mProjectPP to node: Host 27
-> [0.000000] [test/INFO] Scheduling ID00001@mProjectPP to node: Host 28
-> [0.000000] [test/INFO] Scheduling ID00002@mProjectPP to node: Host 29
-> [0.000000] [test/INFO] Scheduling ID00003@mProjectPP to node: Host 30
-> [0.000000] [test/INFO] Scheduling ID00004@mProjectPP to node: Host 31
-> [0.000000] [test/INFO] Scheduling ID00005@mDiffFit to node: Host 32
-> [0.000000] [test/INFO] Scheduling ID00006@mDiffFit to node: Host 26
-> [0.000000] [test/INFO] Scheduling ID00007@mDiffFit to node: Host 27
-> [0.000000] [test/INFO] Scheduling ID00008@mDiffFit to node: Host 28
-> [0.000000] [test/INFO] Scheduling ID00009@mDiffFit to node: Host 29
-> [0.000000] [test/INFO] Scheduling ID00010@mDiffFit to node: Host 30
-> [0.000000] [test/INFO] Scheduling ID00011@mDiffFit to node: Host 31
-> [0.000000] [test/INFO] Scheduling ID00012@mDiffFit to node: Host 32
-> [0.000000] [test/INFO] Scheduling ID00013@mDiffFit to node: Host 26
-> [0.000000] [test/INFO] Scheduling ID00014@mConcatFit to node: Host 27
-> [0.000000] [test/INFO] Scheduling ID00015@mBgModel to node: Host 28
-> [0.000000] [test/INFO] Scheduling ID00016@mBackground to node: Host 29
-> [0.000000] [test/INFO] Scheduling ID00017@mBackground to node: Host 30
-> [0.000000] [test/INFO] Scheduling ID00018@mBackground to node: Host 31
-> [0.000000] [test/INFO] Scheduling ID00019@mBackground to node: Host 32
-> [0.000000] [test/INFO] Scheduling ID00020@mBackground to node: Host 26
-> [0.000000] [test/INFO] Scheduling ID00021@mImgTbl to node: Host 27
-> [0.000000] [test/INFO] Scheduling ID00022@mAdd to node: Host 28
-> [0.000000] [test/INFO] Scheduling ID00023@mShrink to node: Host 29
-> [0.000000] [test/INFO] Scheduling ID00024@mJPEG to node: Host 30
-> [0.000000] [test/INFO] Scheduling end to node: Host 26
-> [0.000000] [test/INFO] DAX scheduled
-> [163.990688] [test/INFO] Simulation done.
-