Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
simgrid.git
18 months agoprofile: cosmetics: inline a function and rename a variable
Martin Quinson [Sat, 2 Feb 2019 17:13:16 +0000 (18:13 +0100)]
profile: cosmetics: inline a function and rename a variable

18 months agos:k:profile: turn two functions into static methods
Martin Quinson [Sat, 2 Feb 2019 16:59:51 +0000 (17:59 +0100)]
s:k:profile: turn two functions into static methods

18 months agoalign file position to the C++ namespaces
Martin Quinson [Sat, 2 Feb 2019 08:02:49 +0000 (09:02 +0100)]
align file position to the C++ namespaces

18 months agoproperly split init/start for Exec activities
Frederic Suter [Sat, 2 Feb 2019 10:17:15 +0000 (11:17 +0100)]
properly split init/start for Exec activities

18 months agoMerge branch 'master' of https://framagit.org/simgrid/simgrid
Frederic Suter [Sat, 2 Feb 2019 08:45:46 +0000 (09:45 +0100)]
Merge branch 'master' of https://framagit.org/simgrid/simgrid

18 months agomake sure to define _FILE_OFFSET_BITS as early as possible
Martin Quinson [Fri, 1 Feb 2019 22:56:17 +0000 (23:56 +0100)]
make sure to define _FILE_OFFSET_BITS as early as possible

It won't be effective if defined after the system headers are loaded.

18 months agoPlease codacy, forget about Catch2
Martin Quinson [Fri, 1 Feb 2019 21:29:06 +0000 (22:29 +0100)]
Please codacy, forget about Catch2

18 months agodoc: reword to remove crufts of the old cunit
Martin Quinson [Fri, 1 Feb 2019 21:28:16 +0000 (22:28 +0100)]
doc: reword to remove crufts of the old cunit

18 months agotidy some #includes in MC
Martin Quinson [Fri, 1 Feb 2019 20:54:07 +0000 (21:54 +0100)]
tidy some #includes in MC

18 months agoPlease Sonar.
Arnaud Giersch [Fri, 1 Feb 2019 20:52:53 +0000 (21:52 +0100)]
Please Sonar.

18 months agoRemove last references to testall.
Arnaud Giersch [Fri, 1 Feb 2019 20:40:35 +0000 (21:40 +0100)]
Remove last references to testall.

18 months agofactor surf_action_ in ActivityImpl
Frederic Suter [Fri, 1 Feb 2019 19:42:25 +0000 (20:42 +0100)]
factor surf_action_ in ActivityImpl

18 months agouniform naming across activities
Frederic Suter [Fri, 1 Feb 2019 16:30:31 +0000 (17:30 +0100)]
uniform naming across activities

18 months agocosmetics
Frederic Suter [Fri, 1 Feb 2019 16:30:02 +0000 (17:30 +0100)]
cosmetics

18 months ago[sonar] Split declarations, unshadow variables.
Arnaud Giersch [Fri, 1 Feb 2019 14:43:25 +0000 (15:43 +0100)]
[sonar] Split declarations, unshadow variables.

18 months agoRIP cunit.
Arnaud Giersch [Fri, 1 Feb 2019 14:03:47 +0000 (15:03 +0100)]
RIP cunit.

18 months agoConvert the unit tests of xbt::config to Catch2.
Arnaud Giersch [Fri, 1 Feb 2019 13:58:38 +0000 (14:58 +0100)]
Convert the unit tests of xbt::config to Catch2.

18 months agoConvert the unit tests of xbt::str to Catch2.
Arnaud Giersch [Thu, 31 Jan 2019 22:18:06 +0000 (23:18 +0100)]
Convert the unit tests of xbt::str to Catch2.

18 months agoConvert the unit tests of xbt::dict to Catch2.
Arnaud Giersch [Thu, 31 Jan 2019 20:25:26 +0000 (21:25 +0100)]
Convert the unit tests of xbt::dict to Catch2.

18 months agoReduce number of #include.
Arnaud Giersch [Thu, 31 Jan 2019 15:32:57 +0000 (16:32 +0100)]
Reduce number of #include.

18 months agoCheck for emptyness, and populate dynar before testing xbt_dynar_foreach_ptr.
Arnaud Giersch [Thu, 31 Jan 2019 15:16:37 +0000 (16:16 +0100)]
Check for emptyness, and populate dynar before testing xbt_dynar_foreach_ptr.

18 months agoproperly split init and start for IO activities
Frederic Suter [Fri, 1 Feb 2019 12:07:18 +0000 (13:07 +0100)]
properly split init and start for IO activities

18 months agoIgnore Catch2 in sonar
Martin Quinson [Thu, 31 Jan 2019 20:35:01 +0000 (21:35 +0100)]
Ignore Catch2 in sonar

18 months agoRevert "Try to improve coverage reports for MC tests."
Arnaud Giersch [Thu, 31 Jan 2019 14:29:41 +0000 (15:29 +0100)]
Revert "Try to improve coverage reports for MC tests."

This reverts commit db3df03114cb65a9c27c2c1dfd6faf964b571254.

The following tests are broken (timeout): mc-bugged1-liveness-visited-ucontext,
mc-bugged1-liveness-visited-ucontext-sparse and mc-umpire-comm-dup-no-free2.

To reproduce, it seems that compile_optimizations should be disabled.

18 months agofix makedist
Martin Quinson [Thu, 31 Jan 2019 09:08:33 +0000 (10:08 +0100)]
fix makedist

18 months agoConvert the unit tests of xbt::dynar to Catch2
Martin Quinson [Thu, 31 Jan 2019 08:52:56 +0000 (09:52 +0100)]
Convert the unit tests of xbt::dynar to Catch2

18 months agocosmetics
Martin Quinson [Thu, 31 Jan 2019 08:52:05 +0000 (09:52 +0100)]
cosmetics

18 months agoTry to improve coverage reports for MC tests.
Arnaud Giersch [Wed, 30 Jan 2019 22:36:47 +0000 (23:36 +0100)]
Try to improve coverage reports for MC tests.

18 months agoDefine coverage_checkpoint().
Arnaud Giersch [Wed, 30 Jan 2019 22:36:05 +0000 (23:36 +0100)]
Define coverage_checkpoint().

It's defined as an alias for __gcov_flush() when coverage is enabled, or a
no-op otherwise.

18 months agoDefine COVERAGE for C++ too.
Arnaud Giersch [Wed, 30 Jan 2019 20:41:07 +0000 (21:41 +0100)]
Define COVERAGE for C++ too.

18 months agoRemove unused static functions.
Arnaud Giersch [Wed, 30 Jan 2019 09:14:20 +0000 (10:14 +0100)]
Remove unused static functions.

18 months agoRefactorize and speedup a unit test
Martin Quinson [Thu, 31 Jan 2019 08:03:35 +0000 (09:03 +0100)]
Refactorize and speedup a unit test

I don't think there is a real need to test each region size from 1 to
256. Testing on [1;32[ should give a sufficient coverage, I think.

18 months agoRemove the now useless unit_test_framework
Martin Quinson [Thu, 31 Jan 2019 07:45:29 +0000 (08:45 +0100)]
Remove the now useless unit_test_framework

18 months agoconvert the two other boost::unit_test suites to Catch2
Martin Quinson [Thu, 31 Jan 2019 07:42:53 +0000 (08:42 +0100)]
convert the two other boost::unit_test suites to Catch2

18 months agoConvert a first unit test to Catch
Martin Quinson [Thu, 31 Jan 2019 00:06:47 +0000 (01:06 +0100)]
Convert a first unit test to Catch

18 months agoAdd the Catch header
Martin Quinson [Wed, 30 Jan 2019 23:39:49 +0000 (00:39 +0100)]
Add the Catch header

This is a header-only library for unit-testing. Including the header
in our project is the recommended way of using it. No need to test for
its presence, then.

Boost::unit_test_framework shall soon vanish from our tree. Testing
for its presence is too bothersome, and Catch seems easier to use
anyway.

18 months agosonar: kill unused imports in java
Martin Quinson [Wed, 30 Jan 2019 07:06:52 +0000 (08:06 +0100)]
sonar: kill unused imports in java

18 months agouncomment forgotten line, includes smpi_helper in C++ codes as well
Augustin Degomme [Wed, 30 Jan 2019 14:03:37 +0000 (15:03 +0100)]
uncomment forgotten line, includes smpi_helper in C++ codes as well

18 months agoavoid sending misleading log message
Augustin Degomme [Tue, 29 Jan 2019 14:34:37 +0000 (15:34 +0100)]
avoid sending misleading log message

18 months agoOur cmake files are so fragile, fix last changes.
Arnaud Giersch [Wed, 30 Jan 2019 07:21:20 +0000 (08:21 +0100)]
Our cmake files are so fragile, fix last changes.

18 months ago[jenkins] Temporary disable LTO on NixOS/gcc 7.4.0/ld 2.30.
Arnaud Giersch [Tue, 29 Jan 2019 22:01:25 +0000 (23:01 +0100)]
[jenkins] Temporary disable LTO on NixOS/gcc 7.4.0/ld 2.30.

18 months agoOptimize MC builds a bit further.
Arnaud Giersch [Tue, 29 Jan 2019 21:33:01 +0000 (22:33 +0100)]
Optimize MC builds a bit further.

18 months agoContextUnix belongs to Simix.
Arnaud Giersch [Tue, 29 Jan 2019 21:27:04 +0000 (22:27 +0100)]
ContextUnix belongs to Simix.

18 months agoInclude cmake/Flags.cmake after DefinePackages.
Arnaud Giersch [Tue, 29 Jan 2019 21:00:18 +0000 (22:00 +0100)]
Include cmake/Flags.cmake after DefinePackages.

The former uses variables defined in the latter (e.g. MC_SRC).

18 months agoImprove coverage, even with high log threshold.
Arnaud Giersch [Tue, 29 Jan 2019 15:31:30 +0000 (16:31 +0100)]
Improve coverage, even with high log threshold.

18 months agoKill dead code in kademlia examples.
Arnaud Giersch [Tue, 29 Jan 2019 12:34:27 +0000 (13:34 +0100)]
Kill dead code in kademlia examples.

18 months ago[java] Delete broken test.
Arnaud Giersch [Tue, 29 Jan 2019 12:13:23 +0000 (13:13 +0100)]
[java] Delete broken test.

18 months ago[java] Catch StopRequest during VM migration.
Arnaud Giersch [Tue, 29 Jan 2019 10:49:24 +0000 (11:49 +0100)]
[java] Catch StopRequest during VM migration.

18 months ago[sonar] Inform that some properties are overridden by Jenkins.
Arnaud Giersch [Tue, 29 Jan 2019 12:51:54 +0000 (13:51 +0100)]
[sonar] Inform that some properties are overridden by Jenkins.

18 months ago[sonar] Only exclude from coverage a subset of python files.
Arnaud Giersch [Tue, 29 Jan 2019 09:58:05 +0000 (10:58 +0100)]
[sonar] Only exclude from coverage a subset of python files.

18 months agoEnable running parmap_bench for coverage.
Arnaud Giersch [Tue, 29 Jan 2019 09:33:15 +0000 (10:33 +0100)]
Enable running parmap_bench for coverage.

18 months agoparmap_bench: make timeout a runtime parameter.
Arnaud Giersch [Tue, 29 Jan 2019 09:25:21 +0000 (10:25 +0100)]
parmap_bench: make timeout a runtime parameter.

18 months agoKill dead code.
Arnaud Giersch [Tue, 29 Jan 2019 09:11:38 +0000 (10:11 +0100)]
Kill dead code.

This test for mallocators has never been used.

18 months agoProcess.java: reduce the debugging scaffolding now that it works
Martin Quinson [Tue, 29 Jan 2019 08:26:24 +0000 (09:26 +0100)]
Process.java: reduce the debugging scaffolding now that it works

18 months agothis file should not be executable
Martin Quinson [Mon, 28 Jan 2019 14:55:32 +0000 (15:55 +0100)]
this file should not be executable

18 months agoOnly unregister the kill timer once, in maestro context
Martin Quinson [Mon, 28 Jan 2019 08:16:17 +0000 (09:16 +0100)]
Only unregister the kill timer once, in maestro context

18 months agoRemove workaround for g++ 4.8.
Arnaud Giersch [Sun, 27 Jan 2019 21:24:40 +0000 (22:24 +0100)]
Remove workaround for g++ 4.8.

g++ 5.0 or higher is advertised in the doc.

18 months agoImplement xbt::Result with boost::variant.
Arnaud Giersch [Sun, 27 Jan 2019 20:07:06 +0000 (21:07 +0100)]
Implement xbt::Result with  boost::variant.

std::variant is today not an option because it's C++17.

18 months agoFix memleak.
Arnaud Giersch [Sun, 27 Jan 2019 17:33:57 +0000 (18:33 +0100)]
Fix memleak.

The comment seems to be invalidated by commit 4f2d08b0ae4625d32890dc4613e1d842ad0f7b77
"Sanitize the API of this_actor::parallel_execute()"

18 months agoDocument a recent example
Martin Quinson [Sun, 27 Jan 2019 17:48:31 +0000 (18:48 +0100)]
Document a recent example

18 months agoactivity::CommImpl: stick to our naming standards for the fields
Martin Quinson [Sun, 27 Jan 2019 09:03:25 +0000 (10:03 +0100)]
activity::CommImpl: stick to our naming standards for the fields

18 months agohelp scan-build understanding that status is not used unintialized
Martin Quinson [Sat, 26 Jan 2019 20:49:27 +0000 (21:49 +0100)]
help scan-build understanding that status is not used unintialized

18 months agoProperly call Actor::on_destruction() in maestro context
Martin Quinson [Sat, 26 Jan 2019 20:12:37 +0000 (21:12 +0100)]
Properly call Actor::on_destruction() in maestro context

This induces a harmless change in trace-process-migration.tesh and
fixes the s4u-actor-exiting example \o/

18 months agoinline a function
Martin Quinson [Sat, 26 Jan 2019 19:49:06 +0000 (20:49 +0100)]
inline a function

18 months agono need to remove the killed actor from canceled comm: refcounting is working
Martin Quinson [Sat, 26 Jan 2019 19:33:12 +0000 (20:33 +0100)]
no need to remove the killed actor from canceled comm: refcounting is working

18 months agoAutomatic refcounting on the src and dst actors of a comm
Martin Quinson [Sat, 26 Jan 2019 18:09:51 +0000 (19:09 +0100)]
refcounting on the src and dst actors of a comm

18 months agoThe pimpl of s4u objects is const
Martin Quinson [Sat, 26 Jan 2019 17:43:11 +0000 (18:43 +0100)]
The pimpl of s4u objects is const

But the one of activities and the cpu_pimpl of host (the codebase is
not ready yet).

18 months agoalways cancel the comms of killed actors in the context of that actor (not in maestro)
Martin Quinson [Sat, 26 Jan 2019 10:02:31 +0000 (11:02 +0100)]
always cancel the comms of killed actors in the context of that actor (not in maestro)

18 months agoAlways call process_on_exit in the actor context
Martin Quinson [Sat, 26 Jan 2019 08:49:26 +0000 (09:49 +0100)]
Always call process_on_exit in the actor context

18 months agoI'd like to kill that parmap.h at some point
Martin Quinson [Sat, 26 Jan 2019 08:48:59 +0000 (09:48 +0100)]
I'd like to kill that parmap.h at some point

Let's first reduce its visibility

18 months agosonar was right: this if/else if was missing a else
Martin Quinson [Sat, 26 Jan 2019 08:28:25 +0000 (09:28 +0100)]
sonar was right: this if/else if was missing a else

18 months agotrick sonar 'identical sub-expression on both side of >'
Martin Quinson [Fri, 25 Jan 2019 07:10:00 +0000 (08:10 +0100)]
trick sonar 'identical sub-expression on both side of >'

18 months agoRestore final messages in Java examples.
Arnaud Giersch [Fri, 25 Jan 2019 14:20:18 +0000 (15:20 +0100)]
Restore final messages in Java examples.

They should be OK now that the termination of Java processes has been repaired.
These messages were removed by commit d535c50c617ba838b99de4bd251a6ac076774d00
"Somehow fix the killing of actors in Java".

18 months agoTry to silent scan-build.
Arnaud Giersch [Fri, 25 Jan 2019 11:15:11 +0000 (12:15 +0100)]
Try to silent scan-build.

18 months ago[sonar] Don't use default capture for lambda.
Arnaud Giersch [Fri, 25 Jan 2019 09:02:52 +0000 (10:02 +0100)]
[sonar] Don't use default capture for lambda.

18 months ago[sonar] Remove variadic functions.
Arnaud Giersch [Fri, 25 Jan 2019 08:39:47 +0000 (09:39 +0100)]
[sonar] Remove variadic functions.

18 months agoChange helper functions to static methods of StopRequest.
Arnaud Giersch [Thu, 24 Jan 2019 11:04:01 +0000 (12:04 +0100)]
Change helper functions to static methods of StopRequest.

18 months agoMove StopRequest out of Context.
Arnaud Giersch [Thu, 24 Jan 2019 10:56:44 +0000 (11:56 +0100)]
Move StopRequest out of Context.

Using context::Context in fully qualified name was redundant.

18 months ago[sonar] Anonymize unused parameters.
Arnaud Giersch [Thu, 24 Jan 2019 22:28:11 +0000 (23:28 +0100)]
[sonar] Anonymize unused parameters.

18 months agoHelp scan-build not seeing that "status" is initialized.
Arnaud Giersch [Thu, 24 Jan 2019 21:47:41 +0000 (22:47 +0100)]
Help scan-build not seeing that "status" is initialized.

Also kill TODO: source is not known when it's irecv.

18 months agosonar: don't catch exceptions we have no idea about
Martin Quinson [Thu, 24 Jan 2019 18:58:52 +0000 (19:58 +0100)]
sonar: don't catch exceptions we have no idea about

18 months agoRemove useless 2nd parameter "catch_block" for try_n_catch_stoprequest().
Arnaud Giersch [Wed, 23 Jan 2019 22:49:32 +0000 (23:49 +0100)]
Remove useless 2nd parameter "catch_block" for try_n_catch_stoprequest().

18 months agosonar cleanups
Martin Quinson [Thu, 24 Jan 2019 07:06:26 +0000 (08:06 +0100)]
sonar cleanups

- kill dead code
- stick to Java variable naming convention
- prefer isEmpty() to size()==0

18 months agoappveyor: don't test python. mingw cannot deal with pybind11 yet
Martin Quinson [Thu, 24 Jan 2019 06:48:55 +0000 (07:48 +0100)]
appveyor: don't test python. mingw cannot deal with pybind11 yet

18 months agoadd a small comment about the memleak introduced here
Martin Quinson [Thu, 24 Jan 2019 06:45:50 +0000 (07:45 +0100)]
add a small comment about the memleak introduced here

18 months agoStop using Context::StopRequest directly in libsimgrid-java.
Arnaud Giersch [Wed, 23 Jan 2019 22:22:58 +0000 (23:22 +0100)]
Stop using Context::StopRequest directly in libsimgrid-java.

18 months agoDefine helper functions to use Context::StopRequest outside of libsimgrid.
Arnaud Giersch [Wed, 23 Jan 2019 22:17:48 +0000 (23:17 +0100)]
Define helper functions to use Context::StopRequest outside of libsimgrid.

Rationale: exceptions sometimes fail to pass correctly between shared
libraries, specially on FreeBSD or OS X.

18 months agoHope to fix double-free: task may by destroyed on finalize().
Arnaud Giersch [Wed, 23 Jan 2019 20:35:53 +0000 (21:35 +0100)]
Hope to fix double-free: task may by destroyed on finalize().

18 months agoMerge remote-tracking branch 'github/master'
Arnaud Giersch [Wed, 23 Jan 2019 20:36:58 +0000 (21:36 +0100)]
Merge remote-tracking branch 'github/master'

18 months agocoverage : avoid matching cobertura pattern with jacoco files
Augustin Degomme [Wed, 23 Jan 2019 14:38:33 +0000 (15:38 +0100)]
coverage : avoid matching cobertura pattern with jacoco files

18 months agoUse $PYTHON_EXECUTABLE in tesh files.
Arnaud Giersch [Wed, 23 Jan 2019 13:34:56 +0000 (14:34 +0100)]
Use $PYTHON_EXECUTABLE in tesh files.

18 months agoImprove process termination in Java world.
Arnaud Giersch [Wed, 23 Jan 2019 11:29:45 +0000 (12:29 +0100)]
Improve process termination in Java world.

18 months agoMerge branch 'master' of framagit.org:simgrid/simgrid
Martin Quinson [Wed, 23 Jan 2019 06:58:21 +0000 (07:58 +0100)]
Merge branch 'master' of framagit.org:simgrid/simgrid

18 months agoRemove 2 (out of 3) horrible hacks around Java contexts
Martin Quinson [Wed, 23 Jan 2019 06:37:18 +0000 (07:37 +0100)]
Remove 2 (out of 3) horrible hacks around Java contexts

Previously, we did not even try to kill java contexts because we
failed to do so in some cases.  Now, we try to kill them just like we
kill the other contexts, even if we don't always succeed.

One difficulty comes from the fact that some threads are created from
the C++ (from the deployment file) and then attached to the JVM, while
some others are created from Java directly (when calling new
Process().start()). The C++ vs Java stack is directly inverted between
cases, complicating the try/catch logic.

In practice, in this changeset, we try harder to convert between the
C++ StopRequest and the Java ProcessKilledError at the language
boundaries.

Also, we don't assert that JavaThread::stop() can actually detach the
thread: it won't for threads that are born in Java because their Java
stack was not unwinded yet. So throw a ProcessKilledError for that.

This is not prefect either since we still need to brutally kill the
JVM after the simulation using exit(0). I added some debug functions
to get more information. Just comment the first call to exit(0) in
jmsg.cpp to see the state of all user threads that we failed to
destroy.

They are all in the C++ world, without any [Java] stack, not blocked
on any Java synchronization object. I suspect that the system thread
is terminated, but the C++ std::thread object is still referenced
somewhere, preventing it from being garbage collected. That's weird
that the JVM still waits for them before ending (and thus mandating
the last the Horrible Hack -- exit(0) in the C++ side of the JVM
system process).

Gosh this is complicated. I'd love to have something like pybind11
dealing with all that shit automatically...

18 months agoFix++
Arnaud Giersch [Tue, 22 Jan 2019 22:07:43 +0000 (23:07 +0100)]
Fix++

Got:
> ctest --output-on-failure -R 'java|python'
> 'python'' is not recognized as an internal or external command,
> operable program or batch file.
> Command exited with code 255

18 months agoFix ctest invocation on appveyor.
Arnaud Giersch [Tue, 22 Jan 2019 21:56:22 +0000 (22:56 +0100)]
Fix ctest invocation on appveyor.

18 months agoLast attempt for python/mingw.
Arnaud Giersch [Tue, 22 Jan 2019 21:42:09 +0000 (22:42 +0100)]
Last attempt for python/mingw.

18 months agoMerge branch 'master' of framagit.org:simgrid/simgrid
Martin Quinson [Tue, 22 Jan 2019 21:21:37 +0000 (22:21 +0100)]
Merge branch 'master' of framagit.org:simgrid/simgrid

18 months agoTry to get python compiling even with MinGW
Martin Quinson [Tue, 22 Jan 2019 20:22:02 +0000 (21:22 +0100)]
Try to get python compiling even with MinGW

18 months agoappveyor: also build and test python
Martin Quinson [Tue, 22 Jan 2019 19:57:40 +0000 (20:57 +0100)]
appveyor: also build and test python