Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Make a tesh file for ns3.
authorNavarrop <Pierre.Navarro@imag.fr>
Mon, 1 Aug 2011 09:25:03 +0000 (11:25 +0200)
committerNavarrop <Pierre.Navarro@imag.fr>
Mon, 1 Aug 2011 09:25:25 +0000 (11:25 +0200)
buildtools/Cmake/AddTests.cmake
examples/msg/ns3/One_cluster.xml
examples/msg/ns3/Two_clusters-d.xml
examples/msg/ns3/Two_clusters.xml
examples/msg/ns3/ns3.tesh [new file with mode: 0644]

index a923771..298258f 100644 (file)
@@ -363,6 +363,12 @@ endif(HAVE_RAWCTX)
   endif(HAVE_TRACING)
 endif(HAVE_GTNETS)
 
+if(HAVE_NS3)
+ADD_TEST(msg-ns3-thread            ${CMAKE_BINARY_DIR}/bin/tesh        --cfg contexts/factory:thread           --setenv srcdir=${CMAKE_HOME_DIRECTORY}/examples/msg    --cd ${CMAKE_BINARY_DIR}/examples/msg ${CMAKE_HOME_DIRECTORY}/examples/msg/ns3/ns3.tesh)
+ADD_TEST(msg-ns3-ucontext      ${CMAKE_BINARY_DIR}/bin/tesh    --cfg contexts/factory:ucontext         --setenv srcdir=${CMAKE_HOME_DIRECTORY}/examples/msg    --cd ${CMAKE_BINARY_DIR}/examples/msg ${CMAKE_HOME_DIRECTORY}/examples/msg/ns3/ns3.tesh)
+ADD_TEST(msg-ns3-raw        ${CMAKE_BINARY_DIR}/bin/tesh       --cfg contexts/factory:raw              --setenv srcdir=${CMAKE_HOME_DIRECTORY}/examples/msg    --cd ${CMAKE_BINARY_DIR}/examples/msg ${CMAKE_HOME_DIRECTORY}/examples/msg/ns3/ns3.tesh)
+endif(HAVE_NS3)
+
 IF(HAVE_TRACING)
   ADD_TEST(tracing-ms                          ${CMAKE_BINARY_DIR}/bin/tesh    --setenv bindir=${CMAKE_BINARY_DIR}/examples/msg        --cd ${CMAKE_HOME_DIRECTORY}/examples/msg tracing/ms.tesh)
   ADD_TEST(tracing-categories          ${CMAKE_BINARY_DIR}/bin/tesh    --setenv bindir=${CMAKE_BINARY_DIR}/examples/msg        --cd ${CMAKE_HOME_DIRECTORY}/examples/msg tracing/categories.tesh)
index a638eae..5171642 100644 (file)
@@ -5,15 +5,15 @@
                                |  router  |
        ____________|__________|_____________ backbone
          |   |   |              |     |   |    
-    l0|        l1|     l2|           l97| l96 |   | l99
+    l0|        l1|     l2|            l7|  l6 |   | l9
       |          |       |   ........   |     |   |
       |                                |
-   c-0.me                             c-99.me  
+   c-0.me                             c-9.me   
 -->
 <platform version="3">
 <AS  id="AS0"  routing="Full">
   <cluster id="my_cluster_1" prefix="c-" suffix=".me"
-               radical="0-99"  power="1000000000"    bw="125000000"     lat="5E-5"
+               radical="0-9  power="1000000000"    bw="125000000"     lat="5E-5"
         bb_bw="2250000000" bb_lat="5E-4"/>
 </AS>
 </platform>
index 2921183..3b55cc9 100644 (file)
@@ -2,13 +2,13 @@
 <!DOCTYPE platform SYSTEM "http://simgrid.gforge.inria.fr/simgrid.dtd">
 <platform version="3">
 
-  <process host="c-30.me" function="master">
+  <process host="c-3.me" function="master">
       <argument value="100"/>
-      <argument value="c-160.me"/>
+      <argument value="c-16.me"/>
       <argument value="1"/>
   </process>
 
-  <process host="c-160.me" function="slave">
+  <process host="c-16.me" function="slave">
     <argument value="1"/>
   </process>
      
index 03810af..0aa41ea 100644 (file)
@@ -9,28 +9,28 @@
                                |  router1 |                                                                                    |
        ____________|__________|_____________ csma1                                                     |
          |   |   |              |     |   |                                                            |backbone
-    l0|        l1|     l2|           l97|  l98|   | l99                                                        |
+    l0|        l1|     l2|            l7|   l8|   | l9                                                         |
       |          |       |   ........   |     |   |                                                            |
       |                                |                                                               |
-   c-0.me                             c-99.me                          |
+   c-0.me                             c-9.me                           |
                      ___________________________________________________|
                                  ___|______
                                |              |
                                |  router2 |
        ____________|__________|_____________ csma2
         |    |    |               |     |   |          
- l100|l101|       |           l197| l198|   | l199
+ l10 | l11|       |            l17|  l18|   | l19
      |   |        |   ........    |     |   |
      |                                   |
-   c-100.me                             c-199.me       
+   c-10.me                              c-19.me        
 -->
 <AS  id="AS0"  routing="Full">
   <cluster id="my_cluster_1" prefix="c-" suffix=".me"
-               radical="0-99"  power="1000000000"    bw="125000000"     lat="5E-5"
+               radical="0-9  power="1000000000"    bw="125000000"     lat="5E-5"
         bb_bw="2250000000" bb_lat="5E-4"/>
                
   <cluster id="my_cluster_2" prefix="c-" suffix=".me"
-           radical="100-199" power="1000000000"        bw="125000000"  lat="5E-5"
+           radical="10-19" power="1000000000"  bw="125000000"  lat="5E-5"
            bb_bw="2250000000" bb_lat="5E-4"/>  
        
      <link id="backbone" bandwidth="1250000000" latency="5E-4"/>  
diff --git a/examples/msg/ns3/ns3.tesh b/examples/msg/ns3/ns3.tesh
new file mode 100644 (file)
index 0000000..02c6cb6
--- /dev/null
@@ -0,0 +1,31 @@
+#! ./tesh
+
+p 3hosts 2links
+
+$ ns3/ns3 ${srcdir:=.}/ns3/3hosts_2links_p.xml ${srcdir:=.}/ns3/3hosts_2links_d.xml --cfg=network/model:NS3
+> [0.000000] [xbt_cfg/INFO] Configuration change: Set 'network/model' to 'NS3'
+> [0.000000] [surf_config/INFO] Switching workstation model to compound since you changed the network and/or cpu model(s)
+> [c:slave:(2) 0.700000] [msg_test/INFO] FLOW[1] : Receive 100 bytes from a to c
+
+p 6hosts 3links
+
+$ ns3/ns3 ${srcdir:=.}/ns3/3links-p.xml ${srcdir:=.}/ns3/3links-d.xml --cfg=network/model:NS3
+> [0.000000] [xbt_cfg/INFO] Configuration change: Set 'network/model' to 'NS3'
+> [0.000000] [surf_config/INFO] Switching workstation model to compound since you changed the network and/or cpu model(s)
+> [C1:slave:(2) 0.392000] [msg_test/INFO] FLOW[1] : Receive 100 bytes from S1 to C1
+> [C2:slave:(4) 1.354000] [msg_test/INFO] FLOW[2] : Receive 1000 bytes from S2 to C2
+> [C3:slave:(6) 2.438000] [msg_test/INFO] FLOW[3] : Receive 2000 bytes from S3 to C3
+
+p One cluster
+
+$ ns3/ns3 ${srcdir:=.}/ns3/One_cluster.xml ${srcdir:=.}/ns3/One_cluster-d.xml --cfg=network/model:NS3
+> [0.000000] [xbt_cfg/INFO] Configuration change: Set 'network/model' to 'NS3'
+> [0.000000] [surf_config/INFO] Switching workstation model to compound since you changed the network and/or cpu model(s)
+> [c-6.me:slave:(2) 0.006614] [msg_test/INFO] FLOW[1] : Receive 100 bytes from c-2.me to c-6.me
+
+p Two clusters
+
+$ ns3/ns3 ${srcdir:=.}/ns3/Two_clusters.xml ${srcdir:=.}/ns3/Two_clusters-d.xml --cfg=network/model:NS3
+> [0.000000] [xbt_cfg/INFO] Configuration change: Set 'network/model' to 'NS3'
+> [0.000000] [surf_config/INFO] Switching workstation model to compound since you changed the network and/or cpu model(s)
+> [c-16.me:slave:(2) 0.012453] [msg_test/INFO] FLOW[1] : Receive 100 bytes from c-3.me to c-16.me
\ No newline at end of file