From 236075d9897437d7a58686ccaa78056d268df867 Mon Sep 17 00:00:00 2001 From: Frederic Suter Date: Mon, 14 Mar 2016 16:50:44 +0100 Subject: [PATCH] reorg examples/simdag for better user experience + kill sd_test2 that brings nothing wrt the teshsuite --- .gitignore | 22 +-- examples/simdag/CMakeLists.txt | 18 +- .../sd_availability.c} | 0 .../sd_availability.tesh} | 2 +- .../sd_comm_throttling.c | 0 .../sd_comm_throttling.tesh | 2 +- examples/simdag/{ => fail}/sd_fail.c | 0 examples/simdag/{ => fail}/sd_fail.tesh | 2 +- examples/simdag/goal/CMakeLists.txt | 6 +- examples/simdag/io/CMakeLists.txt | 7 - examples/simdag/io/{io.tesh => sd_io.tesh} | 2 +- examples/simdag/properties/CMakeLists.txt | 7 - .../properties/{sd_prop.c => sd_properties.c} | 0 .../{test_prop.tesh => sd_properties.tesh} | 2 +- examples/simdag/scheduling/CMakeLists.txt | 8 - .../{minmin_test.c => sd_scheduling.c} | 0 .../{test_minmin.tesh => sd_scheduling.tesh} | 2 +- examples/simdag/sd_test2.c | 187 ------------------ examples/simdag/sd_test2.tesh | 7 - examples/simdag/{ => test}/sd_test.c | 0 examples/simdag/{ => test}/sd_test.tesh | 2 +- .../simdag/{ => typed_tasks}/sd_typed_tasks.c | 0 .../{ => typed_tasks}/sd_typed_tasks.tesh | 2 +- tools/cmake/DefinePackages.cmake | 3 - 24 files changed, 26 insertions(+), 255 deletions(-) rename examples/simdag/{sd_avail.c => availability/sd_availability.c} (100%) rename examples/simdag/{sd_avail.tesh => availability/sd_availability.tesh} (94%) rename examples/simdag/{ => comm_throttling}/sd_comm_throttling.c (100%) rename examples/simdag/{ => comm_throttling}/sd_comm_throttling.tesh (88%) rename examples/simdag/{ => fail}/sd_fail.c (100%) rename examples/simdag/{ => fail}/sd_fail.tesh (96%) delete mode 100644 examples/simdag/io/CMakeLists.txt rename examples/simdag/io/{io.tesh => sd_io.tesh} (80%) delete mode 100644 examples/simdag/properties/CMakeLists.txt rename examples/simdag/properties/{sd_prop.c => sd_properties.c} (100%) rename examples/simdag/properties/{test_prop.tesh => sd_properties.tesh} (92%) delete mode 100644 examples/simdag/scheduling/CMakeLists.txt rename examples/simdag/scheduling/{minmin_test.c => sd_scheduling.c} (100%) rename examples/simdag/scheduling/{test_minmin.tesh => sd_scheduling.tesh} (89%) delete mode 100644 examples/simdag/sd_test2.c delete mode 100644 examples/simdag/sd_test2.tesh rename examples/simdag/{ => test}/sd_test.c (100%) rename examples/simdag/{ => test}/sd_test.tesh (95%) rename examples/simdag/{ => typed_tasks}/sd_typed_tasks.c (100%) rename examples/simdag/{ => typed_tasks}/sd_typed_tasks.tesh (85%) diff --git a/.gitignore b/.gitignore index 2efbc5f979..200783707e 100644 --- a/.gitignore +++ b/.gitignore @@ -216,24 +216,16 @@ examples/simdag/dax/dax_test examples/simdag/dot/dot_test examples/simdag/dot/dot_test2 examples/simdag/dot/simulate_dot -examples/simdag/ex_sd_seq_access -examples/simdag/ex_sd_test -examples/simdag/ex_sd_test2 -examples/simdag/ex_sd_test_console examples/simdag/goal/goal_test examples/simdag/io/sd_io -examples/simdag/properties/sd_prop -examples/simdag/scheduling/minmin_test +examples/simdag/properties/sd_properties +examples/simdag/scheduling/sd_scheduling examples/simdag/scheduling/Montage_25.jed -examples/simdag/sd_avail -examples/simdag/sd_comm_throttling -examples/simdag/sd_fail -examples/simdag/sd_seq_access -examples/simdag/sd_test -examples/simdag/sd_test2 -examples/simdag/sd_test_console -examples/simdag/sd_typed_tasks -examples/simdag/simdag_tracing +examples/simdag/availability/sd_availability +examples/simdag/comm_throttling/sd_comm_throttling +examples/simdag/fail/sd_fail +examples/simdag/test/sd_test +examples/simdag/typed_tasks/sd_typed_tasks examples/smpi/bcbench examples/smpi/energy/f77/sef examples/smpi/energy/f90/sef90 diff --git a/examples/simdag/CMakeLists.txt b/examples/simdag/CMakeLists.txt index 1feedb5ce4..efb62abe84 100644 --- a/examples/simdag/CMakeLists.txt +++ b/examples/simdag/CMakeLists.txt @@ -1,12 +1,14 @@ -foreach(x test test2 avail fail typed_tasks comm_throttling) - add_executable (sd_${x} sd_${x}.c) +foreach(x availability fail typed_tasks io properties comm_throttling scheduling test) + add_executable (sd_${x} ${x}/sd_${x}.c) target_link_libraries(sd_${x} simgrid) - set(examples_src ${examples_src} ${CMAKE_CURRENT_SOURCE_DIR}/sd_${x}.c) - set(tesh_files ${tesh_files} ${CMAKE_CURRENT_SOURCE_DIR}/sd_${x}.tesh) + set_target_properties(sd_${x} PROPERTIES RUNTIME_OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/${x}) + set(examples_src ${examples_src} ${CMAKE_CURRENT_SOURCE_DIR}/${x}/sd_${x}.c) + set(tesh_files ${tesh_files} ${CMAKE_CURRENT_SOURCE_DIR}/${x}/sd_${x}.tesh) - ADD_TESH(simdag-${x} --setenv srcdir=${CMAKE_HOME_DIRECTORY}/examples/simdag --cd ${CMAKE_BINARY_DIR}/examples/simdag ${CMAKE_HOME_DIRECTORY}/examples/simdag/sd_${x}.tesh) + ADD_TESH(simdag-${x} --setenv srcdir=${CMAKE_HOME_DIRECTORY}/examples/simdag --cd ${CMAKE_BINARY_DIR}/examples/simdag ${CMAKE_HOME_DIRECTORY}/examples/simdag/${x}/sd_${x}.tesh) endforeach() -set(examples_src ${examples_src} PARENT_SCOPE) -set(tesh_files ${tesh_files} PARENT_SCOPE) -set(bin_files ${bin_files} ${CMAKE_CURRENT_SOURCE_DIR}/platform_script.lua PARENT_SCOPE) +set(examples_src ${examples_src} PARENT_SCOPE) +set(tesh_files ${tesh_files} PARENT_SCOPE) +set(xml_files ${xml_files} ${CMAKE_CURRENT_SOURCE_DIR}/scheduling/Montage_25.xml PARENT_SCOPE) +set(bin_files ${bin_files} ${CMAKE_CURRENT_SOURCE_DIR}/platform_script.lua PARENT_SCOPE) diff --git a/examples/simdag/sd_avail.c b/examples/simdag/availability/sd_availability.c similarity index 100% rename from examples/simdag/sd_avail.c rename to examples/simdag/availability/sd_availability.c diff --git a/examples/simdag/sd_avail.tesh b/examples/simdag/availability/sd_availability.tesh similarity index 94% rename from examples/simdag/sd_avail.tesh rename to examples/simdag/availability/sd_availability.tesh index ef1a13bee9..d046490d4c 100644 --- a/examples/simdag/sd_avail.tesh +++ b/examples/simdag/availability/sd_availability.tesh @@ -2,7 +2,7 @@ p Test of the management of availability traces with simdag -$ $SG_TEST_EXENV ${bindir:=.}/sd_avail ${srcdir:=.}/../platforms/two_hosts.xml +$ $SG_TEST_EXENV ${bindir:=.}/availability/sd_availability ${srcdir:=.}/../platforms/two_hosts.xml > [0.000000] [xbt_cfg/INFO] Switching to the L07 model to handle parallel tasks. > [1.000000] [sd_avail/INFO] link1: bw=125000000, lat=0.000100 > [1.000000] [sd_avail/INFO] Jupiter: speed=12500000 diff --git a/examples/simdag/sd_comm_throttling.c b/examples/simdag/comm_throttling/sd_comm_throttling.c similarity index 100% rename from examples/simdag/sd_comm_throttling.c rename to examples/simdag/comm_throttling/sd_comm_throttling.c diff --git a/examples/simdag/sd_comm_throttling.tesh b/examples/simdag/comm_throttling/sd_comm_throttling.tesh similarity index 88% rename from examples/simdag/sd_comm_throttling.tesh rename to examples/simdag/comm_throttling/sd_comm_throttling.tesh index e754362009..74b6b8bb0a 100644 --- a/examples/simdag/sd_comm_throttling.tesh +++ b/examples/simdag/comm_throttling/sd_comm_throttling.tesh @@ -1,7 +1,7 @@ #! ./tesh p Modify the rate of communication tasks even when they are auto-scheduled -$ $SG_TEST_EXENV ./sd_comm_throttling --cfg=network/TCP_gamma:4194304 ${srcdir:=.}/../platforms/2clusters.xml +$ $SG_TEST_EXENV ./comm_throttling/sd_comm_throttling --cfg=network/TCP_gamma:4194304 ${srcdir:=.}/../platforms/2clusters.xml > [0.000000] [xbt_cfg/INFO] Configuration change: Set 'network/TCP_gamma' to '4194304' > [0.000000] [xbt_cfg/INFO] Switching to the L07 model to handle parallel tasks. > [1.000000] [sd_comm_throttling/INFO] Simulation stopped after 1.0000 seconds diff --git a/examples/simdag/sd_fail.c b/examples/simdag/fail/sd_fail.c similarity index 100% rename from examples/simdag/sd_fail.c rename to examples/simdag/fail/sd_fail.c diff --git a/examples/simdag/sd_fail.tesh b/examples/simdag/fail/sd_fail.tesh similarity index 96% rename from examples/simdag/sd_fail.tesh rename to examples/simdag/fail/sd_fail.tesh index 3fa3c09d3f..e3dc2b1252 100644 --- a/examples/simdag/sd_fail.tesh +++ b/examples/simdag/fail/sd_fail.tesh @@ -2,7 +2,7 @@ p Test of the management of failed tasks simdag -$ $SG_TEST_EXENV ${bindir:=.}/sd_fail ${srcdir:=.}/../platforms/faulty_host.xml +$ $SG_TEST_EXENV ${bindir:=.}/fail/sd_fail ${srcdir:=.}/../platforms/faulty_host.xml > [0.000000] [xbt_cfg/INFO] Switching to the L07 model to handle parallel tasks. > [0.000000] [sd_fail/INFO] First test: COMP_SEQ task > [0.000000] [sd_fail/INFO] Schedule task 'Poor task' on 'Faulty Host' diff --git a/examples/simdag/goal/CMakeLists.txt b/examples/simdag/goal/CMakeLists.txt index 2887013e70..59fdfc6f7c 100644 --- a/examples/simdag/goal/CMakeLists.txt +++ b/examples/simdag/goal/CMakeLists.txt @@ -1,7 +1,3 @@ add_executable (goal_test goal_test.c) target_link_libraries(goal_test simgrid) - -set(examples_src - ${examples_src} - ${CMAKE_CURRENT_SOURCE_DIR}/goal_test.c - PARENT_SCOPE) +set(examples_src ${examples_src} ${CMAKE_CURRENT_SOURCE_DIR}/goal_test.c PARENT_SCOPE) diff --git a/examples/simdag/io/CMakeLists.txt b/examples/simdag/io/CMakeLists.txt deleted file mode 100644 index 34c91a726b..0000000000 --- a/examples/simdag/io/CMakeLists.txt +++ /dev/null @@ -1,7 +0,0 @@ -add_executable (sd_io sd_io.c) -target_link_libraries(sd_io simgrid) - -ADD_TESH(simdag-io --setenv bindir=${CMAKE_BINARY_DIR}/examples/simdag/ --setenv srcdir=${CMAKE_HOME_DIRECTORY}/ --cd ${CMAKE_HOME_DIRECTORY}/examples/ ${CMAKE_HOME_DIRECTORY}/examples/simdag/io/io.tesh) - -set(tesh_files ${tesh_files} ${CMAKE_CURRENT_SOURCE_DIR}/io.tesh PARENT_SCOPE) -set(examples_src ${examples_src} ${CMAKE_CURRENT_SOURCE_DIR}/sd_io.c PARENT_SCOPE) diff --git a/examples/simdag/io/io.tesh b/examples/simdag/io/sd_io.tesh similarity index 80% rename from examples/simdag/io/io.tesh rename to examples/simdag/io/sd_io.tesh index 7e17983f5c..002856003c 100644 --- a/examples/simdag/io/io.tesh +++ b/examples/simdag/io/sd_io.tesh @@ -1,6 +1,6 @@ #! ./tesh -$ ${bindir:=.}/io/sd_io ${srcdir:=.}/examples/platforms/storage/storage.xml +$ ${bindir:=.}/io/sd_io ${srcdir:=.}/../platforms/storage/storage.xml > [0.000000] [sd_io/INFO] Workstation 'denise' mounts 'c:' > [0.000000] [sd_io/INFO] Workstation 'denise' mounts '/home' > [0.000000] [sd_io/INFO] Workstation 'alice' mounts 'c:' diff --git a/examples/simdag/properties/CMakeLists.txt b/examples/simdag/properties/CMakeLists.txt deleted file mode 100644 index 2ba1ca8ace..0000000000 --- a/examples/simdag/properties/CMakeLists.txt +++ /dev/null @@ -1,7 +0,0 @@ -add_executable (sd_prop sd_prop.c) -target_link_libraries(sd_prop simgrid) - -ADD_TESH(simdag-prop --setenv srcdir=${CMAKE_HOME_DIRECTORY}/examples/simdag --cd ${CMAKE_BINARY_DIR}/examples/simdag ${CMAKE_HOME_DIRECTORY}/examples/simdag/properties/test_prop.tesh) - -set(tesh_files ${tesh_files} ${CMAKE_CURRENT_SOURCE_DIR}/test_prop.tesh PARENT_SCOPE) -set(examples_src ${examples_src} ${CMAKE_CURRENT_SOURCE_DIR}/sd_prop.c PARENT_SCOPE) diff --git a/examples/simdag/properties/sd_prop.c b/examples/simdag/properties/sd_properties.c similarity index 100% rename from examples/simdag/properties/sd_prop.c rename to examples/simdag/properties/sd_properties.c diff --git a/examples/simdag/properties/test_prop.tesh b/examples/simdag/properties/sd_properties.tesh similarity index 92% rename from examples/simdag/properties/test_prop.tesh rename to examples/simdag/properties/sd_properties.tesh index bb27cf84f4..77be2a2538 100755 --- a/examples/simdag/properties/test_prop.tesh +++ b/examples/simdag/properties/sd_properties.tesh @@ -2,7 +2,7 @@ p Simple test of simdag with properties -$ $SG_TEST_EXENV properties/sd_prop ${srcdir:=.}/../platforms/prop.xml +$ $SG_TEST_EXENV properties/sd_properties ${srcdir:=.}/../platforms/prop.xml > [0.000000] [xbt_cfg/INFO] Switching to the L07 model to handle parallel tasks. > [0.000000] [test/INFO] Property list for host host1 > [0.000000] [test/INFO] Property: mem has value: 4 diff --git a/examples/simdag/scheduling/CMakeLists.txt b/examples/simdag/scheduling/CMakeLists.txt deleted file mode 100644 index 14929ebe43..0000000000 --- a/examples/simdag/scheduling/CMakeLists.txt +++ /dev/null @@ -1,8 +0,0 @@ -add_executable (minmin_test minmin_test.c) -target_link_libraries(minmin_test simgrid) - -ADD_TESH(simdag-minmin-scheduling --setenv bindir=${CMAKE_BINARY_DIR}/examples/simdag/scheduling --cd ${CMAKE_HOME_DIRECTORY}/examples/simdag/scheduling test_minmin.tesh) - -set(tesh_files ${tesh_files} ${CMAKE_CURRENT_SOURCE_DIR}/test_minmin.tesh PARENT_SCOPE) -set(xml_files ${xml_files} ${CMAKE_CURRENT_SOURCE_DIR}/Montage_25.xml PARENT_SCOPE) -set(examples_src ${examples_src} ${CMAKE_CURRENT_SOURCE_DIR}/minmin_test.c PARENT_SCOPE) diff --git a/examples/simdag/scheduling/minmin_test.c b/examples/simdag/scheduling/sd_scheduling.c similarity index 100% rename from examples/simdag/scheduling/minmin_test.c rename to examples/simdag/scheduling/sd_scheduling.c diff --git a/examples/simdag/scheduling/test_minmin.tesh b/examples/simdag/scheduling/sd_scheduling.tesh similarity index 89% rename from examples/simdag/scheduling/test_minmin.tesh rename to examples/simdag/scheduling/sd_scheduling.tesh index 380679343d..40798d9a43 100644 --- a/examples/simdag/scheduling/test_minmin.tesh +++ b/examples/simdag/scheduling/sd_scheduling.tesh @@ -2,7 +2,7 @@ p Simple test of simdag -$ $SG_TEST_EXENV ${bindir:=.}/minmin_test --log=sd_daxparse.thresh:critical ${srcdir:=.}/../../platforms/simulacrum_7_hosts.xml ${srcdir:=.}/Montage_25.xml +$ $SG_TEST_EXENV ${bindir:=.}/scheduling/sd_scheduling --log=sd_daxparse.thresh:critical ${srcdir:=.}/../platforms/simulacrum_7_hosts.xml ${srcdir:=.}/scheduling/Montage_25.xml > [0.000000] [xbt_cfg/INFO] Switching to the L07 model to handle parallel tasks. > [0.000000] [test/INFO] Schedule ID00002@mProjectPP on Host 27 > [0.000105] [test/INFO] Schedule ID00000@mProjectPP on Host 26 diff --git a/examples/simdag/sd_test2.c b/examples/simdag/sd_test2.c deleted file mode 100644 index 6514f38eb3..0000000000 --- a/examples/simdag/sd_test2.c +++ /dev/null @@ -1,187 +0,0 @@ -/* Copyright (c) 2007-2015. 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 - -#include "simgrid/simdag.h" -#include "xbt/log.h" - -XBT_LOG_NEW_DEFAULT_CATEGORY(sd_test, "Logging specific to this SimDag example"); - -static int nameCompareHosts(const void *n1, const void *n2) -{ - return strcmp(sg_host_get_name(*((sg_host_t *) n1)), sg_host_get_name(*((sg_host_t *) n2))); -} - -int main(int argc, char **argv) -{ - int i, j; - sg_host_t PtoPcomm1_hosts[2]; - sg_host_t PtoPcomm2_hosts[2]; - double PtoPcomm1_table[] = { 0, 12500000, 0, 0 }; /* 100Mb */ - double PtoPcomm2_table[] = { 0, 1250000, 0, 0 }; /* 10Mb */ - double ParComp_wocomm_cost[] = { 1e+9, 1e+9, 1e+9, 1e+9, 1e+9 }; /* 1 Gflop per Proc */ - double *ParComp_wocomm_table; - sg_host_t ParComp_wocomm_hosts[5]; - double *IntraRedist_cost; - double *IntraRedist_table; - sg_host_t IntraRedist_hosts[5]; - double ParComp_wcomm1_cost[] = { 1e+9, 1e+9, 1e+9, 1e+9, 1e+9 }; /* 1 Gflop per Proc */ - double *ParComp_wcomm1_table; - sg_host_t ParComp_wcomm1_hosts[5]; - double *InterRedist_cost; - double *InterRedist_table; - double ParComp_wcomm2_cost[] = { 1e+8, 1e+8, 1e+8, 1e+8, 1e+8 }; /* 1 Gflop per Proc (0.02sec duration) */ - sg_host_t ParComp_wcomm2_hosts[5]; - double final_cost = 5e+9; - double *ParComp_wcomm2_table; - - SD_init(&argc, argv); - - xbt_assert(strstr(argv[1],".xml"), "Unsupported platform description style (not XML): %s", argv[1]); - SD_create_environment(argv[1]); - - /* getting platform infos */ - int n_hosts = sg_host_count(); - const sg_host_t *hosts = sg_host_list(); - - /* sorting hosts by hostname */ - qsort((void *) hosts, n_hosts, sizeof(sg_host_t), nameCompareHosts); - - /* creation of the tasks */ - SD_task_t taskInit = SD_task_create("Initial", NULL, 1.0); - SD_task_t PtoPComm1 = SD_task_create("PtoP Comm 1", NULL, 1.0); - SD_task_t PtoPComm2 = SD_task_create("PtoP Comm 2", NULL, 1.0); - SD_task_t ParComp_wocomm = SD_task_create("Par Comp without comm", NULL, 1.0); - SD_task_t IntraRedist = SD_task_create("intra redist", NULL, 1.0); - SD_task_t ParComp_wcomm1 = SD_task_create("Par Comp with comm 1", NULL, 1.0); - SD_task_t InterRedist = SD_task_create("inter redist", NULL, 1.0); - SD_task_t taskFinal = SD_task_create("Final", NULL, 1.0); - SD_task_t ParComp_wcomm2 = SD_task_create("Par Comp with comm 2", NULL, 1.0); - - /* creation of the dependencies */ - SD_task_dependency_add(NULL, NULL, taskInit, PtoPComm1); - SD_task_dependency_add(NULL, NULL, taskInit, PtoPComm2); - SD_task_dependency_add(NULL, NULL, PtoPComm1, ParComp_wocomm); - SD_task_dependency_add(NULL, NULL, ParComp_wocomm, IntraRedist); - SD_task_dependency_add(NULL, NULL, IntraRedist, ParComp_wcomm1); - SD_task_dependency_add(NULL, NULL, ParComp_wcomm1, InterRedist); - SD_task_dependency_add(NULL, NULL, InterRedist, ParComp_wcomm2); - SD_task_dependency_add(NULL, NULL, ParComp_wcomm2, taskFinal); - SD_task_dependency_add(NULL, NULL, PtoPComm2, taskFinal); - - /* large point-to-point communication (0.1 sec duration) */ - PtoPcomm1_hosts[0] = hosts[0]; - PtoPcomm1_hosts[1] = hosts[1]; - - /* small point-to-point communication (0.01 sec duration) */ - PtoPcomm2_hosts[0] = hosts[0]; - PtoPcomm2_hosts[1] = hosts[2]; - - /* parallel task without intra communications (1 sec duration) */ - ParComp_wocomm_table = xbt_new0(double, 25); - - for (i = 0; i < 5; i++) { - ParComp_wocomm_hosts[i] = hosts[i]; - } - - /* redistribution within a cluster (small latencies) */ - /* each host send (4*2.5Mb =) 10Mb */ - /* bandwidth is shared between 5 flows (0.05sec duration) */ - IntraRedist_cost = xbt_new0(double, 5); - IntraRedist_table = xbt_new0(double, 25); - for (i = 0; i < 5; i++) { - for (j = 0; j < 5; j++) { - if (i == j) - IntraRedist_table[i * 5 + j] = 0.; - else - IntraRedist_table[i * 5 + j] = 312500.; /* 2.5Mb */ - } - } - - for (i = 0; i < 5; i++) { - IntraRedist_hosts[i] = hosts[i]; - } - - /* parallel task with intra communications */ - /* Computation domination (1 sec duration) */ - ParComp_wcomm1_table = xbt_new0(double, 25); - - for (i = 0; i < 5; i++) { - ParComp_wcomm1_hosts[i] = hosts[i]; - } - - for (i = 0; i < 5; i++) { - for (j = 0; j < 5; j++) { - if (i == j) - ParComp_wcomm1_table[i * 5 + j] = 0.; - else - ParComp_wcomm1_table[i * 5 + j] = 312500.; /* 2.5Mb */ - } - } - - /* inter cluster redistribution (big latency on the backbone) */ - /* (0.5sec duration without latency impact) */ - InterRedist_cost = xbt_new0(double, 10); - InterRedist_table = xbt_new0(double, 100); - for (i = 0; i < 5; i++) { - InterRedist_table[i * 10 + i + 5] = 1250000.; /* 10Mb */ - } - - /* parallel task with intra communications */ - /* Communication domination (0.1 sec duration) */ - ParComp_wcomm2_table = xbt_new0(double, 25); - - for (i = 0; i < 5; i++) { - ParComp_wcomm2_hosts[i] = hosts[i + 5]; - } - - for (i = 0; i < 5; i++) { - for (j = 0; j < 5; j++) { - if (i == j) - ParComp_wcomm2_table[i * 5 + j] = 0.; - else - ParComp_wcomm2_table[i * 5 + j] = 625000.; /* 5Mb */ - } - } - - /* scheduling the tasks */ - SD_task_schedule(taskInit, 1, hosts, SD_SCHED_NO_COST, SD_SCHED_NO_COST, -1.0); - SD_task_schedule(PtoPComm1, 2, PtoPcomm1_hosts, SD_SCHED_NO_COST, PtoPcomm1_table, -1.0); - SD_task_schedule(PtoPComm2, 2, PtoPcomm2_hosts, SD_SCHED_NO_COST, PtoPcomm2_table, -1.0); - SD_task_schedule(ParComp_wocomm, 5, ParComp_wocomm_hosts, ParComp_wocomm_cost, ParComp_wocomm_table, -1.0); - SD_task_schedule(IntraRedist, 5, IntraRedist_hosts, IntraRedist_cost, IntraRedist_table, -1.0); - SD_task_schedule(ParComp_wcomm1, 5, ParComp_wcomm1_hosts, ParComp_wcomm1_cost, ParComp_wcomm1_table, -1.0); - SD_task_schedule(InterRedist, 10, hosts, InterRedist_cost, InterRedist_table, -1.0); - SD_task_schedule(ParComp_wcomm2, 5, ParComp_wcomm2_hosts, ParComp_wcomm2_cost, ParComp_wcomm2_table, -1.0); - SD_task_schedule(taskFinal, 1, &(hosts[9]), &final_cost, SD_SCHED_NO_COST, -1.0); - - /* let's launch the simulation! */ - SD_simulate(-1.0); - - XBT_INFO("Simulation time: %f", SD_get_clock()); - - free(ParComp_wocomm_table); - free(IntraRedist_cost); - free(IntraRedist_table); - free(ParComp_wcomm1_table); - free(InterRedist_cost); - free(InterRedist_table); - free(ParComp_wcomm2_table); - - SD_task_destroy(taskInit); - SD_task_destroy(PtoPComm1); - SD_task_destroy(PtoPComm2); - SD_task_destroy(ParComp_wocomm); - SD_task_destroy(IntraRedist); - SD_task_destroy(ParComp_wcomm1); - SD_task_destroy(InterRedist); - SD_task_destroy(ParComp_wcomm2); - SD_task_destroy(taskFinal); - - SD_exit(); - return 0; -} diff --git a/examples/simdag/sd_test2.tesh b/examples/simdag/sd_test2.tesh deleted file mode 100644 index 64d0267ddd..0000000000 --- a/examples/simdag/sd_test2.tesh +++ /dev/null @@ -1,7 +0,0 @@ -#! ./tesh - -p Simple test of simdag - -$ $SG_TEST_EXENV ./sd_test2 ${srcdir:=.}/../platforms/2clusters.xml -> [0.000000] [xbt_cfg/INFO] Switching to the L07 model to handle parallel tasks. -> [3.251960] [sd_test/INFO] Simulation time: 3.251960 diff --git a/examples/simdag/sd_test.c b/examples/simdag/test/sd_test.c similarity index 100% rename from examples/simdag/sd_test.c rename to examples/simdag/test/sd_test.c diff --git a/examples/simdag/sd_test.tesh b/examples/simdag/test/sd_test.tesh similarity index 95% rename from examples/simdag/sd_test.tesh rename to examples/simdag/test/sd_test.tesh index 02e2a7484a..d75bfd1674 100644 --- a/examples/simdag/sd_test.tesh +++ b/examples/simdag/test/sd_test.tesh @@ -2,7 +2,7 @@ p Simple test of simdag -$ $SG_TEST_EXENV ./sd_test ${srcdir:=.}/../platforms/platform.xml +$ $SG_TEST_EXENV ./test/sd_test ${srcdir:=.}/../platforms/platform.xml > [0.000000] [xbt_cfg/INFO] Switching to the L07 model to handle parallel tasks. > [0.000000] [sd_test/INFO] Computation time for 2000000.000000 flops on Jacquelin: 0.014563 > [0.000000] [sd_test/INFO] Computation time for 1000000.000000 flops on Intel: 0.007282 diff --git a/examples/simdag/sd_typed_tasks.c b/examples/simdag/typed_tasks/sd_typed_tasks.c similarity index 100% rename from examples/simdag/sd_typed_tasks.c rename to examples/simdag/typed_tasks/sd_typed_tasks.c diff --git a/examples/simdag/sd_typed_tasks.tesh b/examples/simdag/typed_tasks/sd_typed_tasks.tesh similarity index 85% rename from examples/simdag/sd_typed_tasks.tesh rename to examples/simdag/typed_tasks/sd_typed_tasks.tesh index 01703387c6..57f8c576b2 100644 --- a/examples/simdag/sd_typed_tasks.tesh +++ b/examples/simdag/typed_tasks/sd_typed_tasks.tesh @@ -1,7 +1,7 @@ #! ./tesh p Usage test of simdag's typed tasks -$ $SG_TEST_EXENV ./sd_typed_tasks --cfg=network/TCP_gamma:4194304 ${srcdir:=.}/../platforms/2clusters.xml +$ $SG_TEST_EXENV ./typed_tasks/sd_typed_tasks --cfg=network/TCP_gamma:4194304 ${srcdir:=.}/../platforms/2clusters.xml > [0.000000] [xbt_cfg/INFO] Configuration change: Set 'network/TCP_gamma' to '4194304' > [0.000000] [xbt_cfg/INFO] Switching to the L07 model to handle parallel tasks. > [2.080300] [sd_typed_tasks_test/INFO] Task 'Seq. comp. 1' start time: 0.000000, finish time: 1.000000 diff --git a/tools/cmake/DefinePackages.cmake b/tools/cmake/DefinePackages.cmake index 5b3a7182da..70663298e3 100644 --- a/tools/cmake/DefinePackages.cmake +++ b/tools/cmake/DefinePackages.cmake @@ -980,9 +980,6 @@ set(CMAKEFILES_TXT examples/simdag/dax/CMakeLists.txt examples/simdag/dot/CMakeLists.txt examples/simdag/goal/CMakeLists.txt - examples/simdag/io/CMakeLists.txt - examples/simdag/properties/CMakeLists.txt - examples/simdag/scheduling/CMakeLists.txt examples/smpi/CMakeLists.txt examples/smpi/NAS/CMakeLists.txt -- 2.20.1