Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
one more refactored
authorFrederic Suter <frederic.suter@cc.in2p3.fr>
Wed, 23 Mar 2016 10:49:13 +0000 (11:49 +0100)
committerFrederic Suter <frederic.suter@cc.in2p3.fr>
Wed, 23 Mar 2016 10:49:13 +0000 (11:49 +0100)
examples/msg/CMakeLists.txt
examples/msg/chord/CMakeLists.txt [deleted file]
examples/msg/chord/chord.tesh
tools/cmake/DefinePackages.cmake

index dd4296e..9feaf4b 100644 (file)
@@ -1,4 +1,4 @@
-foreach(x exception migration parallel_task pmm priority properties suspend synchro token_ring)
+foreach(x chord exception migration parallel_task pmm priority properties suspend synchro token_ring)
   add_executable       (${x}     ${x}/${x}.c)
   target_link_libraries(${x}     simgrid)
   set_target_properties(${x}  PROPERTIES RUNTIME_OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/${x})
@@ -11,17 +11,25 @@ foreach(file bourassa fafard ginette jupiter link3 link4 link5)
 endforeach()
 
 set(txt_files    ${txt_files}     ${CMAKE_CURRENT_SOURCE_DIR}/README                       PARENT_SCOPE)
+set(bin_files    ${bin_files}     ${CMAKE_CURRENT_SOURCE_DIR}/chord/generate.py            PARENT_SCOPE)
 set(examples_src ${examples_src}                                                           PARENT_SCOPE)
-set(tesh_files   ${tesh_files}    ${CMAKE_CURRENT_SOURCE_DIR}/parallel_task/parallel_task_energy.tesh      PARENT_SCOPE)
-set(xml_files    ${xml_files}     ${CMAKE_CURRENT_SOURCE_DIR}/priority/priority_d.xml
+set(tesh_files   ${tesh_files}    ${CMAKE_CURRENT_SOURCE_DIR}/chord/chord_crosstraffic.tesh
+                                  ${CMAKE_CURRENT_SOURCE_DIR}/parallel_task/parallel_task_energy.tesh      PARENT_SCOPE)
+set(xml_files    ${xml_files}     ${CMAKE_CURRENT_SOURCE_DIR}/chord/chord.xml
+                                  ${CMAKE_CURRENT_SOURCE_DIR}/chord/chord10.xml
+                                  ${CMAKE_CURRENT_SOURCE_DIR}/priority/priority_d.xml
                                   ${CMAKE_CURRENT_SOURCE_DIR}/properties/properties_d.xml                  PARENT_SCOPE)
 
-foreach(x migration priority properties suspend synchro token_ring)
+foreach(x chord migration priority properties suspend synchro token_ring)
   ADD_TESH_FACTORIES(msg-${x} "thread;ucontext;raw;boost" --setenv bindir=${CMAKE_BINARY_DIR}/examples/msg/${x} --setenv srcdir=${CMAKE_HOME_DIRECTORY}/examples/platforms --cd ${CMAKE_HOME_DIRECTORY}/examples/msg/${x} ${x}.tesh)
 endforeach()
 
-ADD_TESH_FACTORIES(msg-ptask        "thread;ucontext;raw" --setenv srcdir=${CMAKE_HOME_DIRECTORY}/examples/msg --cd ${CMAKE_BINARY_DIR}/examples/msg ${CMAKE_HOME_DIRECTORY}/examples/msg/parallel_task/parallel_task.tesh)
-ADD_TESH_FACTORIES(msg-ptask-energy "thread;ucontext;raw" --setenv srcdir=${CMAKE_HOME_DIRECTORY}/examples/msg --cd ${CMAKE_BINARY_DIR}/examples/msg ${CMAKE_HOME_DIRECTORY}/examples/msg/parallel_task/parallel_task_energy.tesh)
+ADD_TESH_FACTORIES(msg-chord-crosstraffic          "thread;ucontext;raw;boost" --setenv bindir=${CMAKE_BINARY_DIR}/examples/msg/chord --cd ${CMAKE_HOME_DIRECTORY}/examples/msg/chord chord_crosstraffic.tesh)
+ADD_TESH_FACTORIES(msg-chord-crosstraffic-parallel "thread;ucontext;raw" --cfg contexts/nthreads:4 ${CONTEXTS_SYNCHRO} --setenv bindir=${CMAKE_BINARY_DIR}/examples/msg/chord --cd ${CMAKE_HOME_DIRECTORY}/examples/msg/chord chord_crosstraffic.tesh)
+ADD_TESH_FACTORIES(msg-chord-parallel              "thread;ucontext;raw" --cfg contexts/nthreads:4 ${CONTEXTS_SYNCHRO} --setenv bindir=${CMAKE_BINARY_DIR}/examples/msg/chord --setenv srcdir=${CMAKE_HOME_DIRECTORY}/examples/platforms --cd ${CMAKE_HOME_DIRECTORY}/examples/msg/chord chord.tesh)
+ADD_TESH_FACTORIES(msg-ptask                       "thread;ucontext;raw" --setenv srcdir=${CMAKE_HOME_DIRECTORY}/examples/msg --cd ${CMAKE_BINARY_DIR}/examples/msg ${CMAKE_HOME_DIRECTORY}/examples/msg/parallel_task/parallel_task.tesh)
+ADD_TESH_FACTORIES(msg-ptask-energy                "thread;ucontext;raw" --setenv srcdir=${CMAKE_HOME_DIRECTORY}/examples/msg --cd ${CMAKE_BINARY_DIR}/examples/msg ${CMAKE_HOME_DIRECTORY}/examples/msg/parallel_task/parallel_task_energy.tesh)
+
 ADD_TESH(msg-pmm  --setenv srcdir=${CMAKE_HOME_DIRECTORY}/examples/msg --cd ${CMAKE_BINARY_DIR}/examples/msg ${CMAKE_HOME_DIRECTORY}/examples/msg/pmm/pmm.tesh)
 # This one is not usable:
 # ADD_TESH_FACTORIES(msg-exception "thread;ucontext;raw" --setenv srcdir=${CMAKE_HOME_DIRECTORY}/examples/msg --cd ${CMAKE_BINARY_DIR}/examples/msg ${CMAKE_HOME_DIRECTORY}/examples/msg/exception/exception.tesh)
diff --git a/examples/msg/chord/CMakeLists.txt b/examples/msg/chord/CMakeLists.txt
deleted file mode 100644 (file)
index 75a27a5..0000000
+++ /dev/null
@@ -1,14 +0,0 @@
-add_executable       (chord chord.c)
-target_link_libraries(chord simgrid)
-
-ADD_TESH_FACTORIES(msg-chord                   "thread;ucontext;raw;boost" --setenv bindir=${CMAKE_BINARY_DIR}/examples/msg/chord --cd ${CMAKE_HOME_DIRECTORY}/examples/msg/chord chord_crosstraffic.tesh)
-ADD_TESH_FACTORIES(msg-chord-no-crosstraffic   "thread;ucontext;raw;boost" --setenv bindir=${CMAKE_BINARY_DIR}/examples/msg/chord --cd ${CMAKE_HOME_DIRECTORY}/examples/msg/chord chord.tesh)
-ADD_TESH_FACTORIES(msg-chord-parallel                 "thread;ucontext;raw" --cfg contexts/nthreads:4 ${CONTEXTS_SYNCHRO} --setenv bindir=${CMAKE_BINARY_DIR}/examples/msg/chord --cd ${CMAKE_HOME_DIRECTORY}/examples/msg/chord chord_crosstraffic.tesh)
-ADD_TESH_FACTORIES(msg-chord-no-crosstraffic-parallel "thread;ucontext;raw" --cfg contexts/nthreads:4 ${CONTEXTS_SYNCHRO} --setenv bindir=${CMAKE_BINARY_DIR}/examples/msg/chord --cd ${CMAKE_HOME_DIRECTORY}/examples/msg/chord chord.tesh)
-
-set(tesh_files    ${tesh_files}    ${CMAKE_CURRENT_SOURCE_DIR}/chord.tesh
-                                   ${CMAKE_CURRENT_SOURCE_DIR}/chord_crosstraffic.tesh  PARENT_SCOPE)
-set(xml_files     ${xml_files}     ${CMAKE_CURRENT_SOURCE_DIR}/chord.xml
-                                   ${CMAKE_CURRENT_SOURCE_DIR}/chord10.xml              PARENT_SCOPE)
-set(examples_src  ${examples_src}  ${CMAKE_CURRENT_SOURCE_DIR}/chord.c                  PARENT_SCOPE)
-set(bin_files     ${bin_files}     ${CMAKE_CURRENT_SOURCE_DIR}/generate.py              PARENT_SCOPE)
index ec7d079..ea3c5cc 100644 (file)
@@ -3,7 +3,7 @@
 p Testing the Chord implementation with MSG
 
 ! output sort 19
-$ $SG_TEST_EXENV ${bindir:=.}/chord$EXEEXT -nb_bits=6 ${srcdir:=.}/../../platforms/platform.xml ${srcdir:=.}/chord.xml --cfg=network/crosstraffic:0 --log=msg_chord.thres:verbose "--log=root.fmt:[%10.6r]%e(%i:%P@%h)%e%m%n"
+$ $SG_TEST_EXENV ${bindir:=.}/chord$EXEEXT -nb_bits=6 ${srcdir:=.}/platform.xml ${srcdir:=.}/../msg/chord/chord.xml --cfg=network/crosstraffic:0 --log=msg_chord.thres:verbose "--log=root.fmt:[%10.6r]%e(%i:%P@%h)%e%m%n"
 > [  0.000000] (0:maestro@) Configuration change: Set 'network/crosstraffic' to '0'
 > [  0.000000] (1:node@Gatien) Joining the ring with id 48, knowing node 1
 > [  0.000000] (2:node@McGee) Joining the ring with id 42, knowing node 1
@@ -457,7 +457,7 @@ $ $SG_TEST_EXENV ${bindir:=.}/chord$EXEEXT -nb_bits=6 ${srcdir:=.}/../../platfor
 > [804.364963] (0:maestro@) Simulated time: 804.365
 
 ! output sort 19
-$ $SG_TEST_EXENV ${bindir:=.}/chord$EXEEXT ${srcdir:=.}/../../platforms/routing_none.xml ${srcdir:=.}/chord10.xml --cfg=network/crosstraffic:0 --log=msg_chord.thres:verbose "--log=root.fmt:[%11.6r]%e(%i:%P@%h)%e%m%n" --cfg=network/model:Constant
+$ $SG_TEST_EXENV ${bindir:=.}/chord$EXEEXT ${srcdir:=.}/routing_none.xml ${srcdir:=.}/../msg/chord/chord10.xml --cfg=network/crosstraffic:0 --log=msg_chord.thres:verbose "--log=root.fmt:[%11.6r]%e(%i:%P@%h)%e%m%n" --cfg=network/model:Constant
 > [   0.000000] (0:maestro@) Configuration change: Set 'network/crosstraffic' to '0'
 > [   0.000000] (0:maestro@) Configuration change: Set 'network/model' to 'Constant'
 > [   0.000000] (1:node@node-0.acme.org) My finger table:
index 3e41773..edc715f 100644 (file)
@@ -946,7 +946,6 @@ set(CMAKEFILES_TXT
     examples/msg/actions/CMakeLists.txt
     examples/msg/bittorrent/CMakeLists.txt
     examples/msg/chainsend/CMakeLists.txt
-    examples/msg/chord/CMakeLists.txt
     examples/msg/cloud/CMakeLists.txt
     examples/msg/energy/CMakeLists.txt
     examples/msg/gtnets/CMakeLists.txt