Martin Quinson [Fri, 31 Mar 2023 16:33:59 +0000 (18:33 +0200)]
Try to please the ultramodern clang running on FreeBSD by properly giving a copy operator to the abstract class too
We should stop using the copy operator, and use a nice and clean
clone() call instead. Mathieu's on it.
Martin Quinson [Fri, 31 Mar 2023 14:41:39 +0000 (16:41 +0200)]
Fix doc on how to select the compiler before compiling
Martin Quinson [Fri, 31 Mar 2023 15:59:36 +0000 (15:59 +0000)]
Merge branch 'master' into 'master'
Guiding Backtrack in DFSExplorer
See merge request simgrid/simgrid!143
Arnaud Giersch [Fri, 31 Mar 2023 14:56:04 +0000 (16:56 +0200)]
[gitlab-ci] Run "make distcheck-configure" for merge requests.
Arnaud Giersch [Fri, 31 Mar 2023 14:48:02 +0000 (16:48 +0200)]
Allow to skip some stages of "make distcheck".
Now:
* "make distcheck-archive" only checks the archive
* "make distcheck-configure" also runs cmake et checks the file MANIFEST.in
* "make distcheck" depends on the previous stages, and runs the full build+install+tests
Martin Quinson [Fri, 31 Mar 2023 14:39:21 +0000 (16:39 +0200)]
Correctly select the clang compiler on gitlab CI
Martin Quinson [Fri, 31 Mar 2023 13:58:32 +0000 (15:58 +0200)]
Gitlab CI: Use clang on modelchecker builds, for MRs
Martin Quinson [Fri, 31 Mar 2023 13:55:42 +0000 (15:55 +0200)]
Fix clang builds
Martin Quinson [Wed, 29 Mar 2023 08:00:25 +0000 (10:00 +0200)]
Add a small implementation note in MC
Martin Quinson [Fri, 31 Mar 2023 11:54:08 +0000 (11:54 +0000)]
Merge branch 'master' into 'master'
Add battery plugin and fix DAG doc
See merge request simgrid/simgrid!142
Adrien [Fri, 31 Mar 2023 11:54:07 +0000 (11:54 +0000)]
Add battery plugin and fix DAG doc
mlaurent [Thu, 30 Mar 2023 20:15:33 +0000 (22:15 +0200)]
Merge branch 'master' of https://framagit.org/simgrid/simgrid
mlaurent [Thu, 30 Mar 2023 20:09:31 +0000 (22:09 +0200)]
Rename guide as strategy and fix counter-example display with recipe
mlaurent [Thu, 30 Mar 2023 13:04:28 +0000 (15:04 +0200)]
Replace state copy with recipe: list of transition to replay a state
Arnaud Giersch [Wed, 29 Mar 2023 10:32:40 +0000 (12:32 +0200)]
Cosmetics (help project_description.sh) [ci-skip].
Arnaud Giersch [Wed, 29 Mar 2023 09:01:22 +0000 (11:01 +0200)]
[jenkins] Remove stale sockets from simgrid-mc.
mlaurent [Wed, 29 Mar 2023 08:27:18 +0000 (10:27 +0200)]
Add missing file
mlaurent [Tue, 28 Mar 2023 11:55:17 +0000 (13:55 +0200)]
Change opened states for a priority queue
mlaurent [Mon, 27 Mar 2023 20:43:54 +0000 (22:43 +0200)]
Abide by both compiler warnings
mlaurent [Mon, 27 Mar 2023 18:19:28 +0000 (20:19 +0200)]
Now handle random transition and multiple times transitions
mlaurent [Mon, 27 Mar 2023 08:24:38 +0000 (10:24 +0200)]
Merge branch 'master' of https://framagit.org/simgrid/simgrid
Martin Quinson [Mon, 27 Mar 2023 07:00:50 +0000 (09:00 +0200)]
Activate the stdobject test now that it works
Martin Quinson [Mon, 27 Mar 2023 07:00:25 +0000 (09:00 +0200)]
Don't set a really short timeout on sendsend now that this test works
Martin Quinson [Sun, 26 Mar 2023 20:01:11 +0000 (22:01 +0200)]
Revert "Revalidate tesh files now that safety checking is based on reforks"
We can revert this, as we don't re-initialize again and again the
application in refork mode. Instead, we fork a pre-initialized app.
This reverts commit
b2a9ee8e090af818cca9e72cd0e44fa1b91586b0.
Martin Quinson [Sun, 26 Mar 2023 19:56:46 +0000 (21:56 +0200)]
Implement reforks by forking the application, to save the app exec time
Instead of forking from the checker and exec()ing the application, we
now fork+exec an application that we use as a proxy to the real
application process.
When we need a new application process, we fork it from the proxy,
which is much faster as it's already initialized.
The extra complexity is when the socket closes abruptly on the Checker
side, which means that the application died. We cannot waitpid() on
the app directly, as it's our grandchild. So, we have to ask the proxy
to do the waitpid for us and return the status.
Martin Quinson [Sun, 26 Mar 2023 19:43:31 +0000 (21:43 +0200)]
Allow up to 30 elements in ENUM_CLASS
Martin Quinson [Sat, 25 Mar 2023 15:33:06 +0000 (16:33 +0100)]
memset 0 the memory that is sent over the network
Martin Quinson [Sat, 25 Mar 2023 15:06:56 +0000 (16:06 +0100)]
MC protocol: rename INITIAL_ADDRESSES msg to NEED_MEMINFO
Martin Quinson [Sat, 25 Mar 2023 14:36:41 +0000 (15:36 +0100)]
Actually, now that the appside is not ptraced, there is no point killing it
Closing the socket is enough; it will exit on its self.
Also, there is no point waitpid()ing it, as the libevent loop is
already doing so.
Martin Quinson [Sat, 25 Mar 2023 11:17:28 +0000 (12:17 +0100)]
Invert another logic error: we need ptrace when we need mem_info, not the opposite
Martin Quinson [Sat, 25 Mar 2023 10:24:06 +0000 (11:24 +0100)]
This test is always false, as we asserted so just above
Martin Quinson [Sat, 25 Mar 2023 10:18:58 +0000 (11:18 +0100)]
Do not ask for memory info when restarting in refork mode
Martin Quinson [Fri, 24 Mar 2023 22:33:21 +0000 (23:33 +0100)]
Use a portable name for SIGABRT
Martin Quinson [Fri, 24 Mar 2023 22:32:59 +0000 (23:32 +0100)]
That test seems to pass nowadays
Martin Quinson [Fri, 24 Mar 2023 22:10:43 +0000 (23:10 +0100)]
Try to use the same test file for non-linux now that we don't use ptrace
Martin Quinson [Fri, 24 Mar 2023 22:06:32 +0000 (23:06 +0100)]
MC: disable personality() as it fails on CI and is not mandatory
Martin Quinson [Fri, 24 Mar 2023 21:06:47 +0000 (22:06 +0100)]
Revalidate tesh files now that safety checking is based on reforks
Martin Quinson [Fri, 24 Mar 2023 21:06:04 +0000 (22:06 +0100)]
Fix the refork feature by not ptracing App so that it dies properly
Martin Quinson [Fri, 24 Mar 2023 21:00:34 +0000 (22:00 +0100)]
More explicit error message
Martin Quinson [Thu, 23 Mar 2023 23:00:53 +0000 (00:00 +0100)]
Fix another sonar warning
Arnaud Giersch [Fri, 24 Mar 2023 13:54:41 +0000 (14:54 +0100)]
Delete redundant blank lines at the start of a code blocks (CodeFactor).
mlaurent [Fri, 24 Mar 2023 15:23:47 +0000 (16:23 +0100)]
Add copy constructor to state, so we can backtrack different ways
Arnaud Giersch [Fri, 24 Mar 2023 13:02:57 +0000 (14:02 +0100)]
Strengthen debug messages on channel send/recv.
Arnaud Giersch [Thu, 23 Mar 2023 11:10:25 +0000 (12:10 +0100)]
Simplify member initialization.
Arnaud Giersch [Mon, 20 Mar 2023 10:31:24 +0000 (11:31 +0100)]
Fix test: program needs exactly 2 processes.
Arnaud Giersch [Thu, 16 Mar 2023 16:28:51 +0000 (17:28 +0100)]
Reduce scope for variable.
Arnaud Giersch [Mon, 20 Feb 2023 18:24:23 +0000 (19:24 +0100)]
Simplify loop.
Arnaud Giersch [Mon, 20 Feb 2023 18:19:19 +0000 (19:19 +0100)]
Determine n_transitions on receiving side (and remove it from the message).
Arnaud Giersch [Mon, 20 Feb 2023 18:15:17 +0000 (19:15 +0100)]
There's no need to compute the total transition count anymore.
Arnaud Giersch [Mon, 20 Feb 2023 18:07:25 +0000 (19:07 +0100)]
Remove superfluous test, and reduce depth of nested statements.
Arnaud Giersch [Mon, 20 Feb 2023 18:07:07 +0000 (19:07 +0100)]
Merge loops and get rid of the "probes" temporary vector.
mlaurent [Fri, 24 Mar 2023 09:16:12 +0000 (10:16 +0100)]
Merge branch 'master' of https://framagit.org/simgrid/simgrid
Martin Quinson [Thu, 23 Mar 2023 21:38:38 +0000 (22:38 +0100)]
Dont use handle_waitpid after we killed the App, as this function may report this as an error
Martin Quinson [Thu, 23 Mar 2023 20:58:46 +0000 (21:58 +0100)]
Actually, read()=0 is not an issue in the AppSide
it simply means that the checker closed the socket on its side, so we
should quit ASAP without complaining.
mlaurent [Thu, 23 Mar 2023 08:58:49 +0000 (09:58 +0100)]
Merge branch 'master' of https://framagit.org/simgrid/simgrid
mlaurent [Thu, 23 Mar 2023 08:50:33 +0000 (09:50 +0100)]
try to fix stack handling
Martin Quinson [Wed, 22 Mar 2023 22:04:28 +0000 (23:04 +0100)]
Fix some easy sonar smells
const-ness, try_emplace, attribute noreturn, ...
The most important one is the TransitionObjectAccess one, where a
field in the subclass was hiding a field of the same name in the
superclass. Maybe the bug I was experiencing in that area was related.
Martin Quinson [Wed, 22 Mar 2023 21:35:16 +0000 (22:35 +0100)]
Fix two sonar bugs
- don't throw from the destructor
- don't slice objects (downcast objects instead of downcasting
references). I suspect that this one is a false positive but the
tests still pass this way so let's go.
Martin Quinson [Wed, 22 Mar 2023 20:57:01 +0000 (21:57 +0100)]
Change an example to take its platform file from the command line if provided
Martin Quinson [Wed, 22 Mar 2023 20:43:42 +0000 (20:43 +0000)]
Merge branch 'udpor-phase6' into 'master'
Phase 6 of UDPOR Integration: Add `K`-partial alternatives computation + clean up phase
See merge request simgrid/simgrid!139
Martin Quinson [Wed, 22 Mar 2023 08:17:12 +0000 (09:17 +0100)]
jenkins::Flags if you run the tests, be verbose on errors [no-ci]
Martin Quinson [Tue, 21 Mar 2023 20:48:55 +0000 (21:48 +0100)]
Make sure that the dtor of CheckerSide actually kills the application and waits for it
Martin Quinson [Tue, 21 Mar 2023 20:06:51 +0000 (21:06 +0100)]
Fix the liveness tests when the reforks are compiled in but not activated
mlaurent [Tue, 21 Mar 2023 10:55:16 +0000 (11:55 +0100)]
fix order of execute_next calls
Martin Quinson [Mon, 20 Mar 2023 22:44:59 +0000 (23:44 +0100)]
Manually handle the memory associated to the libevent events
The previous version with std::unique_ptr resulted in segfaults errors
reported by valgrind, and I fail to get it right.
Martin Quinson [Mon, 20 Mar 2023 22:27:39 +0000 (23:27 +0100)]
Do not initialize the App's memory introspection if it's not needed
Reforks are still not activated in this code, as the DFS constructor
pretends that it needs memory introspection when it does not. The
version activating reforks is currently commented here, if you want to
play with it.
Things seem more or less working with this change. Known issues:
- liveness checking is killed by a out-of-bounds access to a vector
while handling the property automaton. This is the case even when
reforks are not activated, making this change improper for the
master branch.
- The checker is not very good at killing the application in refork
mode, and many processes remain around until after they are
abandoned by their checker.
I'm not sure of whether they only consume memory or whether they
also burn the CPU in an active loop. In both cases, this is ...
suboptimal.
This point is OK when not activating reforks.
- valgrind reports some sort of double free on the libevent's events.
I fail to get the std::unique_ptr thing right. See next commit.
Martin Quinson [Mon, 20 Mar 2023 16:09:17 +0000 (17:09 +0100)]
Put everything in position to re-fork the verified App
If you pass "need_memory_introspection = false" to the Exploration
constructor, then the application is re-forked systematically instead
of taking snapshot that are then restored.
But it's still in progress, in the sense that the memory is still
introspected even if we don't need it. The network protocol still
needs to be changed so that the memory info are asked only if
"need_memory_introspection = true" and not otherwise.
For the time being, using reforks is very memory intensive for some
reason, and my computers gets to its knees when running the tests.
Until after the OOM killer saves me by cleaning stuff.
mlaurent [Mon, 20 Mar 2023 15:52:48 +0000 (16:52 +0100)]
Merge branch 'master' of https://framagit.org/simgrid/simgrid
mlaurent [Mon, 20 Mar 2023 15:52:22 +0000 (16:52 +0100)]
add wait guide and mofidication for the heuristic computation
Maxwell Pirtle [Mon, 20 Mar 2023 08:41:58 +0000 (09:41 +0100)]
Address minor comments in MR review
Maxwell Pirtle [Mon, 20 Mar 2023 08:38:12 +0000 (09:38 +0100)]
Remove empty Comb.cpp
Maxwell Pirtle [Mon, 20 Mar 2023 08:33:34 +0000 (09:33 +0100)]
Add documentation for Comb data structure
The Comb data structure lacked documentation
prior to this commit. Since it plays a pretty
important role in the computation of `K`-partial
alternatives, it was given a more extensive
explanation to ensure that it was used properly.
Martin Quinson [Sun, 19 Mar 2023 20:15:10 +0000 (21:15 +0100)]
cosmetics
Martin Quinson [Sun, 19 Mar 2023 20:07:00 +0000 (21:07 +0100)]
Move more of the CheckerSide creation logic to the object constructor
Martin Quinson [Sun, 19 Mar 2023 18:45:39 +0000 (19:45 +0100)]
MC: disable Address Space Layout Randomization in the application
This will allow to re-fork the application on restore without
invalidating all the metadata we accumulated in the previous
exploration traces.
Martin Quinson [Sun, 19 Mar 2023 15:18:05 +0000 (16:18 +0100)]
Differ the creation of the RemoteProcessMemory to when we have enough information
Martin Quinson [Sun, 19 Mar 2023 14:57:19 +0000 (15:57 +0100)]
Better responsabilities splitup between CheckerSide and RemoteProcessMemory
Martin Quinson [Sun, 19 Mar 2023 14:20:23 +0000 (15:20 +0100)]
Move methods not related to Memory out of RemoteProcessMemory
Now that ModelChecker is gone, it's time to move to the next step of cleanup.
The goal is that CheckerSide is in charge of the interaction with the
application process and RemoteProcessMemory is in charge of its memory.
Right now, RemoteProcessMemory does a bit more, as it stores the pid
and whether or not the application process is running.
This is bad because we want to make RemoteProcessMemory optional, only
used when we need to introspect the application memory (liveness
checking, non-progression checking, etc), so that we can run the app
in valgrind when we don't need to introspect its memory (safety
checking without non-progression checking).
I know I just moved this chunks of code from ModelChecker to
RemoteProcessMemory to now move it further, and I'm sorry for the
noise, but this code drives me nuts and I need to clean it step by step.
Martin Quinson [Sun, 19 Mar 2023 14:01:44 +0000 (15:01 +0100)]
Finally kill the now empty ModelChecker class
Martin Quinson [Sun, 19 Mar 2023 13:50:37 +0000 (14:50 +0100)]
Move the memory handling of RemoteProcessMemory singleton from ModelChecker to CheckerSide
Martin Quinson [Sun, 19 Mar 2023 13:29:05 +0000 (14:29 +0100)]
Move handle_message from ModelChecker to RemoteProcessMemory
Martin Quinson [Sun, 19 Mar 2023 12:54:23 +0000 (13:54 +0100)]
Move handle_waitpid from ModelChecker to RemoteProcessMemory
Martin Quinson [Sun, 19 Mar 2023 11:46:57 +0000 (12:46 +0100)]
Make a global singleton of Exploration, to kill ModelChecker
Having global singletons is far from optimal, but it's a bit like the
EngineImpl singleton in the model-checker process.
This will allow to kill the ModelChecker class which responsabilities
were split between RemoteApp and Exploration.
Martin Quinson [Sun, 19 Mar 2023 11:15:58 +0000 (12:15 +0100)]
Gosh, how many calls to that global were there?
Martin Quinson [Sun, 19 Mar 2023 11:09:07 +0000 (12:09 +0100)]
Kill a now unused class in mc
Martin Quinson [Sun, 19 Mar 2023 09:58:20 +0000 (10:58 +0100)]
Remove some more usage of mc_model_checker in Region and snapshoting logic
Martin Quinson [Sun, 19 Mar 2023 09:10:34 +0000 (10:10 +0100)]
Another use of mc_model_checker disapears. In Snapshot.equals.
I guess that this could be done in a better way, as noted in the
comment.
Martin Quinson [Sun, 19 Mar 2023 08:52:48 +0000 (09:52 +0100)]
another mc_model_checker call location disappears
I postponned this one a lot because it's impacting non-MC code, but at
the end it went smoothly
Martin Quinson [Sun, 19 Mar 2023 08:13:06 +0000 (09:13 +0100)]
Fix make distcheck
mlaurent [Sat, 18 Mar 2023 22:29:33 +0000 (23:29 +0100)]
Merge branch 'master' of https://framagit.org/simgrid/simgrid
mlaurent [Sat, 18 Mar 2023 22:29:03 +0000 (23:29 +0100)]
Bases for wait distance guide
Martin Quinson [Sat, 18 Mar 2023 21:49:00 +0000 (22:49 +0100)]
Fix MC+clang builds
Martin Quinson [Sat, 18 Mar 2023 20:49:57 +0000 (21:49 +0100)]
Reduce a bit the adherance of handle_waitpid to ModelChecker
Martin Quinson [Sat, 18 Mar 2023 21:21:14 +0000 (21:21 +0000)]
Merge branch 'master' into 'master'
First step for guided state
See merge request simgrid/simgrid!141
mlaurent [Sat, 18 Mar 2023 14:58:43 +0000 (15:58 +0100)]
Move DPOR and sleep set algorithm from backtrack to run procedure
mlaurent [Sat, 18 Mar 2023 13:48:00 +0000 (14:48 +0100)]
Merge branch 'master' of https://framagit.org/simgrid/simgrid
mlaurent [Sat, 18 Mar 2023 13:46:53 +0000 (14:46 +0100)]
Replace todo direct access with consider methods; guided or not
mlaurent [Sat, 18 Mar 2023 13:05:13 +0000 (14:05 +0100)]
BasicGuide handle next_transition if asked to
Martin Quinson [Sat, 18 Mar 2023 11:21:30 +0000 (12:21 +0100)]
Merge CheckerSide::start() intp the constructor
Martin Quinson [Sat, 18 Mar 2023 11:05:09 +0000 (12:05 +0100)]
Better split of responsabilities between CheckerSide and RemoteApp
Define in CheckerSide the callbacks that are used in there, instead of
defining it in the RemoteApp and passing it along to the CheckerSide.
Let's be optimistic: this code is every day a bit less messy.