Arnaud Giersch [Fri, 2 Sep 2022 12:34:02 +0000 (14:34 +0200)]
Revert change erroneously introduced in commit
223f79c1a096e4157772f8bc3b4f5cdf5161b524
Arnaud Giersch [Fri, 2 Sep 2022 12:26:18 +0000 (14:26 +0200)]
Do not mangle recorded paths when building for coverage.
... and see if it helps for coverage reports (cobertura, sonar, ...)
Arnaud Giersch [Wed, 31 Aug 2022 13:15:57 +0000 (15:15 +0200)]
Use std::string_view (sonar).
Arnaud Giersch [Wed, 31 Aug 2022 13:12:42 +0000 (15:12 +0200)]
Reduce scope for global variables.
Arnaud Giersch [Mon, 29 Aug 2022 16:14:45 +0000 (18:14 +0200)]
Increase test timeout for coverage too.
[ci-ckip]
Arnaud Giersch [Mon, 29 Aug 2022 14:06:22 +0000 (16:06 +0200)]
Try gcovr with option --gcov-ignore-parse-errors.
It seems to help locally.
Arnaud Giersch [Sat, 27 Aug 2022 16:41:07 +0000 (18:41 +0200)]
Use the init-statement to declare variables inside the if statement.
Augustin Degomme [Mon, 29 Aug 2022 08:20:28 +0000 (08:20 +0000)]
Merge branch 'adegomme-master-patch-45262' into 'master'
let's see if this finds more coverage reports
See merge request simgrid/simgrid!117
Augustin Degomme [Mon, 29 Aug 2022 08:04:18 +0000 (08:04 +0000)]
let's see if this finds more coverage reports
Arnaud Giersch [Sat, 27 Aug 2022 13:07:38 +0000 (15:07 +0200)]
Guard against invalid idx.
Fixes tests mbi_ParamMatching_Com_Exscan_ok, mbi_ParamMatching_Com_Scan_ok.
Arnaud Giersch [Fri, 26 Aug 2022 13:52:46 +0000 (15:52 +0200)]
Type consistency.
Arnaud Giersch [Fri, 26 Aug 2022 13:36:05 +0000 (15:36 +0200)]
Attribute "printf" for ModelChecker::dot_output.
Arnaud Giersch [Fri, 26 Aug 2022 13:23:21 +0000 (15:23 +0200)]
Don't throw an exception from destructor.
boost::circular_buffer_space_optimized::pop_back() may throw std::bad_alloc
Arnaud Giersch [Fri, 26 Aug 2022 13:13:01 +0000 (15:13 +0200)]
Arnaud Giersch [Fri, 26 Aug 2022 12:51:20 +0000 (14:51 +0200)]
Reduce depth of nested statements
Arnaud Giersch [Fri, 26 Aug 2022 12:48:09 +0000 (14:48 +0200)]
Don't give write permissions to others with mkdir.
Arnaud Giersch [Fri, 26 Aug 2022 09:16:07 +0000 (11:16 +0200)]
Use "std::vector" instead of C-style array (sonar).
Arnaud Giersch [Fri, 26 Aug 2022 09:09:30 +0000 (11:09 +0200)]
Avoid to send/receive zero-size messages.
There seems to be something broken with them on freebsd.
Arnaud Giersch [Thu, 25 Aug 2022 12:20:58 +0000 (14:20 +0200)]
Arnaud Giersch [Thu, 25 Aug 2022 10:01:06 +0000 (12:01 +0200)]
Misc cosmetics for sonar.
Arnaud Giersch [Thu, 25 Aug 2022 09:59:17 +0000 (11:59 +0200)]
Remove temporary object (sonar).
Arnaud Giersch [Thu, 25 Aug 2022 09:51:15 +0000 (11:51 +0200)]
Declare functions "const" (sonar).
Arnaud Giersch [Thu, 25 Aug 2022 09:29:58 +0000 (11:29 +0200)]
Make parameters pointer/reference-to-const (sonar).
Arnaud Giersch [Wed, 10 Aug 2022 15:05:41 +0000 (17:05 +0200)]
Kill redundant blank lines (codefactor.io)
[ci-skip]
Augustin Degomme [Wed, 10 Aug 2022 20:56:52 +0000 (20:56 +0000)]
[ci-skip] try to help gcovr find files (it needs to be run in the same dir as gcc)
Martin Quinson [Tue, 9 Aug 2022 21:05:46 +0000 (23:05 +0200)]
MC: apply some sonar advices
Arnaud Giersch [Tue, 9 Aug 2022 20:39:20 +0000 (22:39 +0200)]
Fix the fixme (inline templated struct).
Arnaud Giersch [Tue, 9 Aug 2022 20:30:44 +0000 (22:30 +0200)]
Unused include.
Augustin Degomme [Tue, 9 Aug 2022 15:14:56 +0000 (17:14 +0200)]
remove spurious debug message and warning
Augustin Degomme [Tue, 9 Aug 2022 14:29:31 +0000 (16:29 +0200)]
update teshes
Augustin Degomme [Tue, 9 Aug 2022 14:23:54 +0000 (16:23 +0200)]
multiple attemps to tune behavior of read/write_all
Augustin Degomme [Tue, 9 Aug 2022 14:23:11 +0000 (16:23 +0200)]
fix mpi_file set/get view to set shared pointer properly and return disp
Augustin Degomme [Tue, 9 Aug 2022 14:21:24 +0000 (16:21 +0200)]
update file pointer to match shared one after shared calls when needed
Augustin Degomme [Tue, 9 Aug 2022 14:13:53 +0000 (16:13 +0200)]
seek and other calls must use number of elements and not bytes displacement
Augustin Degomme [Tue, 9 Aug 2022 14:12:18 +0000 (16:12 +0200)]
update teshes as there are now more seek calls
Augustin Degomme [Tue, 9 Aug 2022 14:10:42 +0000 (16:10 +0200)]
smpi io: restore position after calls which should not modify it (add seek calls which are not ideal but harmless)
Augustin Degomme [Tue, 9 Aug 2022 14:03:17 +0000 (16:03 +0200)]
s4u filesystem: correctly update size of files when changed
Augustin Degomme [Tue, 9 Aug 2022 14:00:13 +0000 (16:00 +0200)]
intercept getpid call in SMPI, to provide internal PID instead of same of for all processes.
Augustin Degomme [Tue, 9 Aug 2022 13:56:32 +0000 (15:56 +0200)]
implement MPI_File_get_type_extent, MPI_File_s/get_atomicity, MPI_File_get_byte_offset
Augustin Degomme [Sat, 6 Aug 2022 10:51:12 +0000 (12:51 +0200)]
filesystem, correctly update file size when seeking past it
Martin Quinson [Mon, 8 Aug 2022 23:17:39 +0000 (01:17 +0200)]
Don't test statequality: it's ~15h w/o DPOR and hard to optimize
Martin Quinson [Mon, 8 Aug 2022 22:55:45 +0000 (00:55 +0200)]
Correctly disable DPOR when StateEq reduction is enabled
Martin Quinson [Mon, 8 Aug 2022 21:15:13 +0000 (23:15 +0200)]
Add the teshfiles to the archive even when MC is disabled
Martin Quinson [Sun, 7 Aug 2022 23:39:35 +0000 (01:39 +0200)]
Add tests of state equality reduction and nodpor for DFS explo
Martin Quinson [Sun, 7 Aug 2022 23:17:54 +0000 (01:17 +0200)]
kill a parameter that is always true
Martin Quinson [Sun, 7 Aug 2022 23:08:48 +0000 (01:08 +0200)]
mc:DFSExplo: cosmetics in the backtracking
Martin Quinson [Sun, 7 Aug 2022 22:29:08 +0000 (00:29 +0200)]
Merge mc_safety.hpp into DFSExplorer class
Martin Quinson [Sun, 7 Aug 2022 21:52:11 +0000 (23:52 +0200)]
Useless cosmetics while trying to understand that code
Martin Quinson [Sun, 7 Aug 2022 17:30:19 +0000 (19:30 +0200)]
Integrate the (WIP) hashing logic in the Snapshot object
Martin Quinson [Sun, 7 Aug 2022 16:51:55 +0000 (18:51 +0200)]
Small cleanups in mc::Snapshot
Martin Quinson [Sat, 6 Aug 2022 23:33:18 +0000 (01:33 +0200)]
Finish the removal of mc::api by moving the last bits to the side
I would prefer to directly kill the templated structure, but I fail to
write a correct comparison lambda because it's used over a
std::vector<std::unique_ptr<simgrid::mc::VisitedState>>
All my attempts lead to either "no conversion to std::unique_ptr<VisitedState>",
or an error saying that I try to copy a unique_ptr when my lambda
takes unique_ptr as a parameter.
Please someone better at C++ than I am, please kill it.
Martin Quinson [Sat, 6 Aug 2022 23:05:56 +0000 (01:05 +0200)]
Move mc:api::get_remote_heap_bytes() to RemoteProcess
Martin Quinson [Sat, 6 Aug 2022 22:33:02 +0000 (00:33 +0200)]
Convert simgrid::mc::snapshot_equal() into Snapshot::operator==()
Also inline 2 more functions from mc::api
Martin Quinson [Sat, 6 Aug 2022 22:13:53 +0000 (00:13 +0200)]
Move the dot_output global into ModelChecker
Martin Quinson [Sat, 6 Aug 2022 21:12:52 +0000 (23:12 +0200)]
Make the RemoteApp a field of the Exploration, and sanitize initialization
Martin Quinson [Thu, 4 Aug 2022 21:55:29 +0000 (23:55 +0200)]
Simplify the MC initialization code
Martin Quinson [Thu, 4 Aug 2022 21:43:57 +0000 (23:43 +0200)]
only 3 more functions to go in mc::api
Martin Quinson [Thu, 4 Aug 2022 19:18:33 +0000 (21:18 +0200)]
Kill another mc::api function
Martin Quinson [Thu, 4 Aug 2022 19:10:48 +0000 (21:10 +0200)]
Pass the remote app as a parameter to all exploration signals
When we'll have reforks in the future, the remote app may change
during the exploration, so we don't want to seal the current remote
app in the callback closure. We want to use the fresh one instead.
Martin Quinson [Thu, 4 Aug 2022 14:28:55 +0000 (16:28 +0200)]
Kill 2 more functions from mc::api
Martin Quinson [Wed, 3 Aug 2022 23:47:04 +0000 (01:47 +0200)]
Move the automaton from mc::api to Liveness. An ugly trick is needed :(
See the comment in Liveness.hpp for the full details on that trick.
Martin Quinson [Tue, 2 Aug 2022 20:56:47 +0000 (22:56 +0200)]
log_state has nothing to do in RemoteApp, it belongs to the exploration
Martin Quinson [Tue, 2 Aug 2022 14:58:56 +0000 (16:58 +0200)]
Sanitize MC finalization process and inline a function
Martin Quinson [Tue, 2 Aug 2022 12:25:03 +0000 (14:25 +0200)]
Kill mc::api::get_remote_app()
Martin Quinson [Tue, 2 Aug 2022 12:06:47 +0000 (14:06 +0200)]
Kill another function of mc::api
Martin Quinson [Tue, 2 Aug 2022 11:45:37 +0000 (13:45 +0200)]
Kill an unimplemented declaration
Martin Quinson [Tue, 2 Aug 2022 11:08:10 +0000 (13:08 +0200)]
Convert Api::get_maxpid() into RemoteApp::get_maxpid()
The patch is a bit complex because RemoteApp is not a singleton, and
because I converted some pointers to references on the way.
Martin Quinson [Tue, 2 Aug 2022 10:04:56 +0000 (12:04 +0200)]
Merge an initialization function into the constructor
Martin Quinson [Tue, 2 Aug 2022 09:15:01 +0000 (11:15 +0200)]
Rename mc::Session into mc::api::RemoteApp
Augustin Degomme [Tue, 2 Aug 2022 18:07:42 +0000 (18:07 +0000)]
[ci-skip] activate ccache on sanitizer builds
Martin Quinson [Mon, 1 Aug 2022 22:21:42 +0000 (00:21 +0200)]
Merge branch 'master' of framagit.org:simgrid/simgrid
Martin Quinson [Mon, 1 Aug 2022 22:15:48 +0000 (00:15 +0200)]
Ensure that the verified application still works if get_max_consider() is not called at a given depth
This can happen after a backtrack: the Checker already knows how many
times this can be considered, but the App was reset in between so it
forgot.
So, make get_max_consider() const, and do the initialization in the
observer constructor, where it belongs. Too bad for the tiny little
tiny loss of performance compared to the lazy initialization.
Augustin Degomme [Mon, 1 Aug 2022 20:34:20 +0000 (20:34 +0000)]
[ci-skip] Flags - let's see if this trailing whitespace was breaking everything..
Augustin Degomme [Mon, 1 Aug 2022 17:36:47 +0000 (17:36 +0000)]
[ci-skip] use ccache on flags build as well.
Restrict build to two nodes with enough disk space, as it's expected to be costly
Martin Quinson [Sun, 31 Jul 2022 14:45:50 +0000 (16:45 +0200)]
Kill a now useless variable
Martin Quinson [Sun, 31 Jul 2022 09:56:56 +0000 (11:56 +0200)]
sanitize things around FINALIZE_REPLY despite my laziness as it seems to break on FreeBSD
Martin Quinson [Sun, 31 Jul 2022 07:28:29 +0000 (09:28 +0200)]
Fix SMPI builds by reintroducing a killed MC function that it actually use
Martin Quinson [Sat, 30 Jul 2022 23:37:40 +0000 (01:37 +0200)]
MC further cleanups (let it compile, this time)
Martin Quinson [Sat, 30 Jul 2022 22:22:41 +0000 (00:22 +0200)]
MC: rename a file to sort out the mess
Martin Quinson [Sat, 30 Jul 2022 22:05:25 +0000 (00:05 +0200)]
And now cleanup the App-side of cruft that was needed for Checker to read actor informations
Martin Quinson [Sat, 30 Jul 2022 21:56:43 +0000 (23:56 +0200)]
Finally kill mc::RemoteProcess::actors(). We now communicate the data over the wire instead of reading it directly
Martin Quinson [Sat, 30 Jul 2022 20:48:42 +0000 (22:48 +0200)]
Give read access to a private field
Martin Quinson [Sat, 30 Jul 2022 20:38:14 +0000 (22:38 +0200)]
inline a function, kill a file
Martin Quinson [Sat, 30 Jul 2022 20:15:05 +0000 (22:15 +0200)]
Well the last rogue call to RemoteProcess::actors() was easy actually
Augustin Degomme [Sat, 30 Jul 2022 18:39:13 +0000 (20:39 +0200)]
try to hide something under the rug for now
Augustin Degomme [Sat, 30 Jul 2022 18:19:15 +0000 (20:19 +0200)]
remove useless field
Augustin Degomme [Sat, 30 Jul 2022 18:18:01 +0000 (20:18 +0200)]
fix build for clang <15
Martin Quinson [Sat, 30 Jul 2022 16:11:44 +0000 (18:11 +0200)]
Liveness: rename graph_state -> app_state and automaton_state -> prop_state
Martin Quinson [Sat, 30 Jul 2022 15:11:26 +0000 (17:11 +0200)]
further reduce the amount of call sites for RemoteProcess::actors()
Martin Quinson [Sat, 30 Jul 2022 14:27:59 +0000 (16:27 +0200)]
small cosmetics to not spread unrelated logic all around the file
Martin Quinson [Sat, 30 Jul 2022 14:16:17 +0000 (16:16 +0200)]
MC: make it clear that we only have the info about the ready-to-run actors in a given mc::State
This is very similar to the exploration algorithm in Simix, but that's
still counter-intuitive when you try to understand the code.
Let's hope that writting it this way will help me not falling into
that trap anymore :)
Martin Quinson [Sat, 30 Jul 2022 14:04:23 +0000 (16:04 +0200)]
Reduce the amount of MC locations reading the memory of the App
We still read the remote memory, but (almost) only when creating a new
State representing that state of the App. The goal is then to get
those info through message passing instead of through memory reading.
That should help reducing the bizarre things done by the MC, maybe
allowing to run the App in valgrind or so.
As a side effect, the exploration code becomes much more readable by
using the info from the mc::State instead of invocking low-level
things to retrive those info.
Augustin Degomme [Sat, 30 Jul 2022 15:00:42 +0000 (17:00 +0200)]
ignore new deprecation warning on freebsd
Augustin Degomme [Sat, 30 Jul 2022 14:29:05 +0000 (14:29 +0000)]
use ccache for main ci build.
It should be available on every builder, so skip detection phase. Will be added if/when needed
Martin Quinson [Fri, 29 Jul 2022 09:15:51 +0000 (11:15 +0200)]
Fix RST formatting + one URL in Release_Notes.rst
Martin Quinson [Fri, 29 Jul 2022 08:18:41 +0000 (10:18 +0200)]
If there is no LOCK in mmalloc anymore, then there is no need for atfork
Martin Quinson [Thu, 28 Jul 2022 23:51:52 +0000 (01:51 +0200)]
Remove the need of pthread_mutex in mmalloc, to allow its use with sthread
Historically, mmalloc was used in all case when MC was activated at
build time (even if MC was not involved at runtime), forcing this
protection against race conditions for e.g. parallel simulations.
But nowadays, mmalloc is only activated at runtime in the verified
application. In other runtime setups, mmalloc uses the libc's malloc
implem instead of itself (that's why we use dlsym in the
initialization of mmalloc, to find the replacement).
So, removing this code should have no impact whatsoever.
Only maybe speeding up the verification a tiny bit.
And now, sthread becomes usable in conjunction with Mc Simgrid!!!
Given the current poor coverage of the pthread API, we can't verify
any useful program, but at least we have a valid (and rather robust)
prototype of such a verification tool.
Arnaud Giersch [Thu, 28 Jul 2022 11:50:37 +0000 (13:50 +0200)]
Stick to dwarf-4 for MC builds.
TODO: add support for dwarf-5
Martin Quinson [Thu, 28 Jul 2022 08:37:30 +0000 (10:37 +0200)]
Kill useless complexity in mmalloc: one of the dlsym
dlsym is not necessary to retrieve the LD_PRELOAD-injected symbol.
The killed code was intended to be used in libsimgrid, trying to
detect when libsgmalloc was already in memory to use that copy
instead. But that's useless: LD_PRELOAD ensures that the copy of the
injected version is the only existing one in the process.
In addition, that may resolve stability issues that my previous commit
didn't solve as nicely on the build daemons than on my laptop with gcc.
Martin Quinson [Thu, 28 Jul 2022 01:06:38 +0000 (03:06 +0200)]
Allow dlsym to call free() on memory that is allocated before mmalloc init
dlsym obviously uses malloc, but we use dlsym while initializing
mmalloc, so we have a static buffer somewhere to give the required
memory to dlsym while mmalloc is not ready to serve. That's old.
Now, since the recent change in mmalloc, dlsym seems to not only
malloc some memory, but it also frees some of the obtained memory.
This commit detects when this happens and react gracefully (by
ignoring the free on that memory) instead of verbosely dying.