Bruno Donassolo [Wed, 28 Apr 2021 09:24:54 +0000 (11:24 +0200)]
Cosmetics
Martin Quinson [Wed, 28 Apr 2021 08:24:37 +0000 (10:24 +0200)]
MC tuto: Review by Emma
Arnaud Giersch [Wed, 28 Apr 2021 06:28:53 +0000 (08:28 +0200)]
Attribute noreturn for terminate handler.
Arnaud Giersch [Tue, 27 Apr 2021 17:00:25 +0000 (19:00 +0200)]
We don't want to survive a ForcefulKillException!
Arnaud Giersch [Sun, 25 Apr 2021 12:14:54 +0000 (14:14 +0200)]
The header <typeinfo> must be included before using typeid.
Bruno Donassolo [Tue, 27 Apr 2021 17:10:27 +0000 (19:10 +0200)]
New example: Fat Tree cluster of multi-cpu hosts(Star Zones)
Adapt existing Torus example for different platforms.
Same idea: each leaf is a new StarZone netzone, emulating a multi-cpu
node.
Bruno Donassolo [Mon, 26 Apr 2021 15:12:13 +0000 (17:12 +0200)]
New: s4u::create_fatTree_zone
Implements the builder method for Fat Tree zones.
Similar signature and behavior of create_torus_zone.
Bruno Donassolo [Tue, 27 Apr 2021 15:27:03 +0000 (17:27 +0200)]
Fix FatTreeZone with limiter links
Are we sure we want this "feature" in complex clusters?
As for Torus, no test using it.
Segfault when communicating with limiter links.
Routers inside the FatTreeZone don't have limiters, even when user sets
the limiter on the XML.
Code was adding nullptr to the list of links in this case, generating a
segfault in communicate function.
Example:
<zone id="world" routing="Full">
<cluster id="bob_cluster"
prefix="node-" radical="0-15" suffix=".simgrid.org"
speed="1Gf" bw="125MBps" lat="50us"
topology="FAT_TREE" topo_parameters="2;4,4;1,2;1,2"
loopback_bw="100MBps" loopback_lat="0" limiter_link="100MBps" />
Martin Quinson [Tue, 27 Apr 2021 15:37:18 +0000 (17:37 +0200)]
First version of a tutorial on Mc SimGrid
Martin Quinson [Tue, 27 Apr 2021 15:36:00 +0000 (17:36 +0200)]
cosmetics
Martin Quinson [Sun, 25 Apr 2021 22:19:56 +0000 (00:19 +0200)]
Add a pointer from the doc sources to the online one
SUTER Frederic [Tue, 27 Apr 2021 13:39:39 +0000 (15:39 +0200)]
add a (modern) wait_any for Io activities. Thx agier!
SUTER Frederic [Tue, 27 Apr 2021 08:22:30 +0000 (10:22 +0200)]
throw signal from seal() directly
Bruno Donassolo [Mon, 26 Apr 2021 16:51:22 +0000 (18:51 +0200)]
Try to please sonar
Bruno Donassolo [Fri, 23 Apr 2021 08:20:11 +0000 (10:20 +0200)]
Improvements in torus test
Use 2 links in Star Zone to simulate full-duplex communications.
Improv doc.
Bruno Donassolo [Wed, 21 Apr 2021 20:12:39 +0000 (22:12 +0200)]
Initialize models together with netzone root
Remove static to initialize models once, anyway we have only one engine
in a simulation by now. Hope someday we'll be able to initialize the
models properly.
Remove workaround in UTs
Bruno Donassolo [Wed, 21 Apr 2021 15:05:37 +0000 (17:05 +0200)]
New example: Torus cluster of multi-cpu hosts(Star Zones)
Add a new example showing how to build a torus cluster composed of
netzones instead of single hosts.
Each leaf is a StarZone, representing a host with 8 CPUs connected in a
star. CPU-0 is the gateway for each StarZone.
Runs a simple broadcast application where each CPU runs a specific
actor.
Bruno Donassolo [Wed, 21 Apr 2021 18:35:03 +0000 (20:35 +0200)]
NetZone::get_netpoint: gets the netzone's netpoint
New method to get the netpoint used by netzones.
Usefull when describing routes using the netzones (add_route method)
Bruno Donassolo [Wed, 21 Apr 2021 10:02:25 +0000 (12:02 +0200)]
Add some UT for TorusZone
Improve some checks.
Bruno Donassolo [Mon, 19 Apr 2021 17:30:26 +0000 (19:30 +0200)]
New: s4u::create_torus_zone
Implements the builder method for Torus zones
NetZone* create_torus_zone(const std::string& name, const NetZone* parent, const std::vector<unsigned int>& dimensions,
double bandwidth, double latency, Link::SharingPolicy sharing_policy,
const std::function<TorusNetPointCb>& set_netpoint,
const std::function<TorusLinkCb>& set_loopback = {},
const std::function<TorusLinkCb>& set_limiter = {});
This builder method allow us to keep hiding the internals of our
NetZones, exporting only a NetZone* to the end-user.
It uses callbacks functions to populate the leaves in the Torus, 3
callbacks can be used:
- set_netpoint: must return a pair NetPoint,Gateway. This allows us to
have complex netzones under each leaf
- set_loopback: The link used to loopback communications
- set_limiter: A limiter link for each leaf
The links inside the Torus are homogeneous and described by the
bandwidth, latency and sharing policy parameters.
As the creation of resources are linked to the netzones (create_host,
create_link functions), we have to add the parent parameter to the
builder function. Otherwise, the user cannot create the resources
associated with the leaves in the callbacks.
Obs.: By now, the sg_platf.cpp isn't using this new builder method.
It will be changed once we have implemented the builder for every
cluster type (fatree, dragonfly).
Arnaud Giersch [Fri, 23 Apr 2021 07:47:07 +0000 (09:47 +0200)]
Rename VirtualMachine::get_impl() to not hide Host::get_impl().
Arnaud Giersch [Thu, 22 Apr 2021 20:45:52 +0000 (22:45 +0200)]
Make SIMIX_simcall_name() use the type of observer_ if it exists.
It gives more information about the kind of simcall being involved,
since most simcalls are nowadays of type RUN_KERNEL or RUN_BLOCKING.
Arnaud Giersch [Thu, 22 Apr 2021 20:27:08 +0000 (22:27 +0200)]
Use std::string::rfind to match string prefix.
Arnaud Giersch [Thu, 22 Apr 2021 20:17:25 +0000 (22:17 +0200)]
Unused #include.
Bruno Donassolo [Thu, 22 Apr 2021 16:47:15 +0000 (18:47 +0200)]
Raise exception for invalid parameters in StarZone
We've talked about using exceptions for invalid parameters in user'
calls.
Adjust for StarZone.
Bonus: We can test it in UT with catch
Arnaud Giersch [Thu, 22 Apr 2021 13:37:36 +0000 (15:37 +0200)]
[sonar] Implicit casts should not lower precision.
Arnaud Giersch [Thu, 22 Apr 2021 10:55:32 +0000 (12:55 +0200)]
Use type aid_t for actor ids.
Arnaud Giersch [Wed, 21 Apr 2021 10:39:19 +0000 (12:39 +0200)]
Factor code for simcall observers with a result.
Arnaud Giersch [Wed, 21 Apr 2021 08:57:07 +0000 (10:57 +0200)]
Cosmetics: make parameter name match with .hpp.
Arnaud Giersch [Wed, 21 Apr 2021 22:02:17 +0000 (00:02 +0200)]
Factor Activity::wait() and wait_for() through CRTP.
Arnaud Giersch [Wed, 21 Apr 2021 21:38:18 +0000 (23:38 +0200)]
Factor Activity::cancel() through CRTP.
Arnaud Giersch [Wed, 21 Apr 2021 21:22:58 +0000 (23:22 +0200)]
Comm::test() is ready to be merged with Activity::test().
Arnaud Giersch [Wed, 21 Apr 2021 07:57:56 +0000 (09:57 +0200)]
Define overridable Activity::complete() to be called on activity completion.
This adds some assignments of State::FINISHED, but it looks like they were
previously forgotten. No test is broken.
Bruno Donassolo [Wed, 21 Apr 2021 15:57:05 +0000 (17:57 +0200)]
Fix TorusZone with limiter links
Raises an std::out_of_range exception when it tries to add the limiter
link to routes.
Example:
<cluster id="bob_cluster" topology="TORUS" topo_parameters="3,2,2"
prefix="node-" radical="0-11" suffix=".simgrid.org"
speed="1Gf" bw="125MBps" lat="50us"
loopback_bw="100MBps" loopback_lat="0" limiter_link="100MBps"/>
Not sure if someone uses this limiter. We don't have any test that uses limiter_link tag inside a
TORUS cluster. It'll be added in with the new C++ interface.
Arnaud Giersch [Tue, 20 Apr 2021 19:35:42 +0000 (21:35 +0200)]
Reduce scope for variable.
Arnaud Giersch [Tue, 20 Apr 2021 13:20:36 +0000 (15:20 +0200)]
Global--.
Arnaud Giersch [Tue, 20 Apr 2021 12:58:05 +0000 (14:58 +0200)]
Another bunch of int -> size_t conversion.
Arnaud Giersch [Tue, 20 Apr 2021 09:29:38 +0000 (11:29 +0200)]
aid_t for src and dst in smpi::Request.
Arnaud Giersch [Tue, 20 Apr 2021 08:03:15 +0000 (10:03 +0200)]
Convert some int -> size_t.
Arnaud Giersch [Tue, 20 Apr 2021 07:39:45 +0000 (09:39 +0200)]
Prefer emplace to insert.
Arnaud Giersch [Tue, 20 Apr 2021 07:22:31 +0000 (09:22 +0200)]
For Sonar.
Arnaud Giersch [Tue, 20 Apr 2021 07:19:32 +0000 (09:19 +0200)]
More aid_t.
Arnaud Giersch [Tue, 20 Apr 2021 07:09:51 +0000 (09:09 +0200)]
Avoid alternative keywords for boolean expressions.
Plus slight simplifications.
Arnaud Giersch [Mon, 19 Apr 2021 20:47:58 +0000 (22:47 +0200)]
Reference for std::vector parameters.
Arnaud Giersch [Mon, 19 Apr 2021 20:28:41 +0000 (22:28 +0200)]
Fix bound checking.
Arnaud Giersch [Mon, 19 Apr 2021 20:19:41 +0000 (22:19 +0200)]
Combine identical conditions.
Arnaud Giersch [Mon, 19 Apr 2021 20:16:07 +0000 (22:16 +0200)]
Use std algorithm.
Arnaud Giersch [Mon, 19 Apr 2021 20:09:58 +0000 (22:09 +0200)]
Useless indirection.
Arnaud Giersch [Mon, 19 Apr 2021 20:02:38 +0000 (22:02 +0200)]
Sonar const's...
Arnaud Giersch [Mon, 19 Apr 2021 19:52:14 +0000 (21:52 +0200)]
Convert int -> size_t for TRACE_smpi_send (and below).
Arnaud Giersch [Mon, 19 Apr 2021 19:08:54 +0000 (21:08 +0200)]
More int -> aid_t.
Arnaud Giersch [Mon, 19 Apr 2021 16:32:58 +0000 (18:32 +0200)]
Use type aid_t for process id. in instr_smpi.
Augustin Degomme [Mon, 19 Apr 2021 14:07:52 +0000 (16:07 +0200)]
Adapt leak example to new display.
Add another leak and a size change between processes to see what it shows.
Augustin Degomme [Mon, 19 Apr 2021 14:06:55 +0000 (16:06 +0200)]
Group buffer leaks by origin as well.
Keep total size and min/max for each if possible, then display by largest total size.
Arnaud Giersch [Mon, 19 Apr 2021 13:55:40 +0000 (15:55 +0200)]
Plug memory leak.
Arnaud Giersch [Mon, 19 Apr 2021 08:16:14 +0000 (10:16 +0200)]
Const, once again.
Martin Quinson [Mon, 19 Apr 2021 10:54:35 +0000 (12:54 +0200)]
Doc improvement [ci-skip]
Martin Quinson [Mon, 19 Apr 2021 10:35:48 +0000 (12:35 +0200)]
Merge branch 'master' of framagit.org:simgrid/simgrid
Arnaud Giersch [Sun, 18 Apr 2021 19:25:37 +0000 (21:25 +0200)]
Finally rename smpi::Group::actor_pid() back to actor().
Arnaud Giersch [Sun, 18 Apr 2021 19:14:49 +0000 (21:14 +0200)]
Kill smpi::Group::rank(s4u::Actor*).
Arnaud Giersch [Sun, 18 Apr 2021 17:01:49 +0000 (19:01 +0200)]
Kill smpi::Group::actor(int).
Arnaud Giersch [Sun, 18 Apr 2021 14:29:22 +0000 (16:29 +0200)]
Change smpi::Group::set_mapping to take a pid.
Arnaud Giersch [Sun, 18 Apr 2021 13:25:41 +0000 (15:25 +0200)]
Add assert's to ensure consistency between the two kinds of mapping.
Arnaud Giersch [Sun, 18 Apr 2021 12:50:09 +0000 (14:50 +0200)]
Define new rank_to_pid_map_.
Arnaud Giersch [Sun, 18 Apr 2021 13:19:44 +0000 (15:19 +0200)]
Lookup for parent process (like in Group::rank(s4u::Actor*).
Arnaud Giersch [Sun, 18 Apr 2021 09:29:36 +0000 (11:29 +0200)]
In smpi::Group, 'index' is in fact a PID. Fix type and rename.
Arnaud Giersch [Sun, 18 Apr 2021 19:19:38 +0000 (21:19 +0200)]
Kill a TODO (-1 is correct for an invalid PID).
Arnaud Giersch [Sun, 18 Apr 2021 09:53:53 +0000 (11:53 +0200)]
MPI_SOURCE is a rank; src_traced should be a PID.
Arnaud Giersch [Sun, 18 Apr 2021 09:38:55 +0000 (11:38 +0200)]
Fix comment.
Arnaud Giersch [Sun, 18 Apr 2021 08:32:08 +0000 (10:32 +0200)]
Pass large parameter by const reference.
Arnaud Giersch [Sat, 17 Apr 2021 19:12:19 +0000 (21:12 +0200)]
Minor cleanups (useless stuff).
Augustin Degomme [Sun, 18 Apr 2021 10:22:44 +0000 (12:22 +0200)]
also requalify mc version of the tesh
Augustin Degomme [Sun, 18 Apr 2021 09:54:44 +0000 (11:54 +0200)]
Group leak reports by type/file/line (for handles, will see for buffer later).
And split reporting.
Arnaud Giersch [Sat, 17 Apr 2021 09:21:27 +0000 (11:21 +0200)]
Sonar polishing.
Arnaud Giersch [Sat, 17 Apr 2021 08:56:54 +0000 (10:56 +0200)]
Pointer-to-const parameters in smpi::Group.
Arnaud Giersch [Sat, 17 Apr 2021 08:52:12 +0000 (10:52 +0200)]
Reduce code duplication (and fix bug in Group::difference).
Arnaud Giersch [Fri, 16 Apr 2021 22:11:41 +0000 (00:11 +0200)]
A for-loop with 'num' modified in the body is too complex according to Sonar.
Arnaud Giersch [Fri, 16 Apr 2021 21:26:14 +0000 (23:26 +0200)]
Fix smpi::Group::intersection().
Using 'size2' for controlling the first loop was a bug (spotted by Sonar).
Arnaud Giersch [Fri, 16 Apr 2021 21:21:02 +0000 (23:21 +0200)]
Fix Group::group_union().
Included ranks from group2 were not good.
Arnaud Giersch [Fri, 16 Apr 2021 21:36:00 +0000 (23:36 +0200)]
Simplify smpi::Group::difference().
Arnaud Giersch [Fri, 16 Apr 2021 19:41:27 +0000 (21:41 +0200)]
Review smpi::Group::*excl() and smpi::Group::*incl().
Mostly cosmetic changes.
Arnaud Giersch [Fri, 16 Apr 2021 20:51:42 +0000 (22:51 +0200)]
Kill redundant member 'size_' from smpi::Group.
Arnaud Giersch [Fri, 16 Apr 2021 16:32:28 +0000 (18:32 +0200)]
Minor changes in smpi::Group.
Arnaud Giersch [Fri, 16 Apr 2021 19:26:02 +0000 (21:26 +0200)]
Remove unused option from example.
Arnaud Giersch [Fri, 16 Apr 2021 14:09:05 +0000 (16:09 +0200)]
Simplify loop searching for a bypass route.
Arnaud Giersch [Fri, 16 Apr 2021 12:59:10 +0000 (14:59 +0200)]
Prefer a do-while in this case, and rewrite without 'break'.
Arnaud Giersch [Fri, 16 Apr 2021 12:29:23 +0000 (14:29 +0200)]
Use std::find_if when looking for a matching comm.
Arnaud Giersch [Fri, 16 Apr 2021 09:29:22 +0000 (11:29 +0200)]
Replace C-style arrays and remove const_cast.
Define local class EngineWrapper to encapsulate common code.
Arnaud Giersch [Fri, 16 Apr 2021 08:59:45 +0000 (10:59 +0200)]
Use const& for std::string parameters.
Arnaud Giersch [Thu, 15 Apr 2021 21:07:15 +0000 (23:07 +0200)]
Pointer-to-const.
Arnaud Giersch [Fri, 16 Apr 2021 13:23:17 +0000 (15:23 +0200)]
Fix build with older clang.
SUTER Frederic [Fri, 16 Apr 2021 12:26:08 +0000 (14:26 +0200)]
please clang take 2
SUTER Frederic [Fri, 16 Apr 2021 12:15:08 +0000 (14:15 +0200)]
please clang
Bruno Donassolo [Fri, 16 Apr 2021 10:33:57 +0000 (12:33 +0200)]
Some code improvements.
Avoid unnecessary map lookups.
Thanks @agiersch for the review
SUTER Frederic [Fri, 16 Apr 2021 10:05:38 +0000 (12:05 +0200)]
add wrappers with scalars on the user side
SUTER Frederic [Thu, 15 Apr 2021 14:03:18 +0000 (16:03 +0200)]
simplification
SUTER Frederic [Thu, 15 Apr 2021 13:55:30 +0000 (15:55 +0200)]
cosmetics
SUTER Frederic [Tue, 13 Apr 2021 18:26:04 +0000 (20:26 +0200)]
cosmetics
Bruno Donassolo [Thu, 15 Apr 2021 13:33:43 +0000 (15:33 +0200)]
s4u::NetZone::create_router.
Export create_router to s4u so we can use in C++ platforms.
Bruno Donassolo [Thu, 15 Apr 2021 08:59:15 +0000 (10:59 +0200)]
Please sonar, just a little