Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Merge branch 'master' of git+ssh://scm.gforge.inria.fr//gitroot/simgrid/simgrid
authorFrederic Suter <frederic.suter@cc.in2p3.fr>
Fri, 22 Jul 2016 12:49:49 +0000 (14:49 +0200)
committerFrederic Suter <frederic.suter@cc.in2p3.fr>
Fri, 22 Jul 2016 12:52:30 +0000 (14:52 +0200)
doc/doxygen/community_giveback.doc
doc/doxygen/options.doc
examples/java/trace/pingpong/trace_pingpong.tesh
include/simgrid/s4u/Activity.hpp
sonar-project.properties
src/bindings/java/jmsg_rngstream.cpp
src/s4u/s4u_actor.cpp

index 8eee215..cc428d0 100644 (file)
@@ -147,6 +147,11 @@ Some support for C++11-style time/duration is implemented (see `chrono.hpp`)
 but only available in some (S4U) APIs. It would be nice to add support for
 them in the rest of the C++ code.
 
+A related change would be to avoid using "-1" to mean "forever" at least in S4U
+and in the internal code. For compatibility, MSG should probably keep this
+semantic. We should probably always use separate functions
+(`wait` vs `wait_for`).
+
 @subsubsection contributing_todo_futures Futures
 
  - Some features are missing in the Maestro future implementation
index 45b5624..2f5f95f 100644 (file)
@@ -199,17 +199,6 @@ the \b maxmin/precision item (default value: 0.00001). Changing it
 may speedup the simulation by discarding very small actions, at the
 price of a reduced numerical precision.
 
-\subsection options_model_nthreads Parallel threads for model updates
-
-By default, Surf computes the analytical models sequentially to share their
-resources and update their actions. It is possible to run them in parallel,
-using the \b surf/nthreads item (default value: 1). If you use a
-negative or null value, the amount of available cores is automatically
-detected  and used instead.
-
-Depending on the workload of the models and their complexity, you may get a
-speedup or a slowdown because of the synchronization costs of threads.
-
 \subsection options_model_network Configuring the Network model
 
 \subsubsection options_model_network_gamma Maximal TCP window size
index 17c954a..a3b011a 100644 (file)
@@ -36,4 +36,4 @@ $ java -classpath ${classpath:=.} trace/pingpong/Main ${srcdir:=.}/../platforms/
 > [Tremblay:Receiver:(3) 2.957786] [jmsg/INFO]  --- bw 1.1627602630025032E8 ----
 > [Tremblay:Receiver:(3) 3.817809] [jmsg/INFO] goodbye!
 
-!$ rm -rf simulation.trace
+$ rm -rf simulation.trace
index fae7fb8..0b8d303 100644 (file)
@@ -33,6 +33,9 @@ protected:
   virtual ~Activity();
 
 public:
+  Activity(Activity const&) = delete;
+  Activity& operator=(Activity const&) = delete;
+
   /** Starts a previously created activity.
    *
    * This function is optional: you can call wait() even if you didn't call start()
index e83783f..2ee090d 100644 (file)
@@ -16,12 +16,21 @@ sonar.sources=src,examples,include,teshsuite
 #  - our unit tests 
 #  - the tests that we borrowed elsewhere (MPICH and ISP)
 #  - Flex-generated files
-sonar.exclusions=src/*_unit.c*,teshsuite/smpi/mpich3-test/*,teshsuite/smpi/isp/*,**/*_dtd.c
+#  - Collectives that we borrowed elsewhere (mpich, openMPI and other implems)
+sonar.exclusions=src/*_unit.c*,teshsuite/smpi/mpich3-test/*,teshsuite/smpi/isp/*,**/*_dtd.c,src/smpi/colls/*
 
 # Ignore files that are generated from Flex
 sonar.issue.ignore.allfile=flexGenerated
 sonar.issue.ignore.allfile.flexGenerated.fileRegexp="generated by flex"
 
+# Ignore the files that SMPI scavenged here and there (not working)
+#sonar.issue.ignore.allfile=mpiColls
+#sonar.issue.ignore.allfile.flexGenerated.mpiColls="Ahmad Faraj"
+#sonar.issue.ignore.allfile=mpivapich
+#sonar.issue.ignore.allfile.flexGenerated.mpivapich="This file is part of the MVAPICH2 software package"
+#sonar.issue.ignore.allfile=mpiOmpi
+#sonar.issue.ignore.allfile.flexGenerated.mpiOmpi="University of Tennessee"
+
 # The build-wrapper output dir
 sonar.cfamily.build-wrapper-output=bw-outputs
 
index 2dda4ca..a7e82b7 100644 (file)
@@ -110,7 +110,13 @@ JNIEXPORT jboolean JNICALL Java_org_simgrid_msg_RngStream_setSeed(JNIEnv *env, j
   if (!rngstream)
     return JNI_FALSE;
 
-  int result = RngStream_SetSeed(rngstream, (unsigned long*)buffer);
+  // The C API expects unsigned long which are wider than int on LP64.
+  // We need to convert:
+  unsigned long seed[6];
+  for (int i = 0; i != 6; ++i)
+    seed[i] = buffer[i];
+
+  int result = RngStream_SetSeed(rngstream, seed);
 
   return result == -1 ? JNI_FALSE : JNI_TRUE;
 }
index d8ad4a2..c53f54a 100644 (file)
@@ -130,14 +130,14 @@ e_smx_state_t execute(double flops) {
 
 void* recv(Mailbox &chan) {
   void *res = nullptr;
-  Comm c = Comm::recv_init(chan);
+  Comm& c = Comm::recv_init(chan);
   c.setDstData(&res,sizeof(res));
   c.wait();
   return res;
 }
 
 void send(Mailbox &chan, void *payload, size_t simulatedSize) {
-  Comm c = Comm::send_init(chan);
+  Comm& c = Comm::send_init(chan);
   c.setRemains(simulatedSize);
   c.setSrcData(payload);
   // c.start() is optional.