Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
simgrid.git
2 years agoRestore public smpi_init_options().
Arnaud Giersch [Fri, 4 Jun 2021 15:45:07 +0000 (17:45 +0200)]
Restore public smpi_init_options().

It was wrongly removed in commit 6a046487fb Make smpi_switch_data_segment check if a switch is needed, and return true when it occurs.

2 years agoFix test on MAC OS
Bruno Donassolo [Fri, 4 Jun 2021 14:37:13 +0000 (16:37 +0200)]
Fix test on MAC OS

2 years agoTry to fix test on CI
Bruno Donassolo [Fri, 4 Jun 2021 12:17:04 +0000 (14:17 +0200)]
Try to fix test on CI

2 years agoAn example with SMPI and CPP platform
Bruno Donassolo [Thu, 3 Jun 2021 13:59:50 +0000 (15:59 +0200)]
An example with SMPI and CPP platform

Shows how to use smpirun to execute an application with the platform described in C++.

2 years agoMinor fix usage
Bruno Donassolo [Thu, 3 Jun 2021 13:59:27 +0000 (15:59 +0200)]
Minor fix usage

2 years agoAdjust test
Bruno Donassolo [Thu, 3 Jun 2021 12:40:31 +0000 (14:40 +0200)]
Adjust test

Empty hostfiles are now checked inside the C++ code, not in smpirun

2 years agoAdjust test
Bruno Donassolo [Thu, 3 Jun 2021 12:40:06 +0000 (14:40 +0200)]
Adjust test

Nodes chosen to run the test arent the same anymore.

2 years agoMinor fix in test.
Bruno Donassolo [Thu, 3 Jun 2021 09:23:45 +0000 (11:23 +0200)]
Minor fix in test.

Just messages order has changed.

2 years agoMoving SMPI app deployment to C++ code
Bruno Donassolo [Wed, 2 Jun 2021 18:11:09 +0000 (20:11 +0200)]
Moving SMPI app deployment to C++ code

Enable the deployment of SMPI experiments with C++ platform description.
Move application deployment from smpirun to smpi_main function.

The smpirun script used to parse the platform XML to create an
application deployment. This isn't possible anymore since we may don't
have a platform XML anymore.

Move the necessary input to smpi_main through specific cfg variables:
- smpi/hostfile: host file
- smpi/replay: replay file
- smpi/np: number of processes
- smpi/map: mapping process/rank

This cfg isn't used by users, they are cached inside the smpirun script.

2 years agoNew platform example: StarZone of StarZone
Bruno Donassolo [Fri, 23 Apr 2021 16:56:43 +0000 (18:56 +0200)]
New platform example: StarZone of StarZone

Re-implements the griffon.xml using the C++ interface.
Simplify the implementation of homogeneous clusters organized in
cabinets.

Add tests in teshsuite to use both files.

2 years agoFix build mac/windows
Bruno Donassolo [Fri, 16 Apr 2021 19:12:18 +0000 (21:12 +0200)]
Fix build mac/windows

2 years agoChange C++ platform example
Bruno Donassolo [Thu, 15 Apr 2021 12:42:50 +0000 (14:42 +0200)]
Change C++ platform example

Remove small_platform.cpp.
Add a more programmatic platform using the StarZone.

2 years agoTry to fix python build
Bruno Donassolo [Wed, 14 Apr 2021 18:31:46 +0000 (20:31 +0200)]
Try to fix python build

Add dependency for dl library.

2 years agoRuns examples with C++ platform description
Bruno Donassolo [Mon, 15 Mar 2021 17:45:25 +0000 (18:45 +0100)]
Runs examples with C++ platform description

*Loading platform
- Generates library files for C++ platforms. They can be loaded by the
engine using the same load_platform method.

- The Engine::load_platform will verify if the extension is .so, it'll
open the file using dlopen and search for the load_platform symbol.

- The platform so must contain a load_platform function that will be
called by the engine to generate the platform properly.

*Implementing an example
- Added a CMakeLists.txt in examples/platform to generate the .so for
each example.

- Pass to the tesh files a new variable "libdir" containing the
directory where the libraries are located.

2 years ago[sonar] Replace redundant type with 'auto'.
Arnaud Giersch [Fri, 4 Jun 2021 08:16:08 +0000 (10:16 +0200)]
[sonar] Replace redundant type with 'auto'.

2 years ago[sonar] Redundant parentheses.
Arnaud Giersch [Fri, 4 Jun 2021 07:40:39 +0000 (09:40 +0200)]
[sonar] Redundant parentheses.

2 years ago[sonar] Pointer-to-const.
Arnaud Giersch [Fri, 4 Jun 2021 07:38:35 +0000 (09:38 +0200)]
[sonar] Pointer-to-const.

2 years agoFix build with enable_smpi=OFF.
Arnaud Giersch [Thu, 3 Jun 2021 15:15:07 +0000 (17:15 +0200)]
Fix build with enable_smpi=OFF.

2 years agoFix include.
Arnaud Giersch [Thu, 3 Jun 2021 14:57:51 +0000 (16:57 +0200)]
Fix include.

2 years agoEnsure correct ordering of the accumulate requests.
Arnaud Giersch [Thu, 3 Jun 2021 13:34:01 +0000 (15:34 +0200)]
Ensure correct ordering of the accumulate requests.

2 years agoUseless test; TODO--.
Arnaud Giersch [Thu, 3 Jun 2021 11:57:25 +0000 (13:57 +0200)]
Useless test; TODO--.

2 years agoInitialize mmap-privatized segments earlier (before main).
Arnaud Giersch [Thu, 3 Jun 2021 11:07:08 +0000 (13:07 +0200)]
Initialize mmap-privatized segments earlier (before main).

Sometimes we may want to initiailze a global before MPI_Init.

2 years agoMake smpi_switch_data_segment check if a switch is needed, and return true when it...
Arnaud Giersch [Thu, 3 Jun 2021 09:28:56 +0000 (11:28 +0200)]
Make smpi_switch_data_segment check if a switch is needed, and return true when it occurs.

Kill global SMPI_switch_data_segment.

2 years agoUse existing function (also empties requests_ after waitall).
Arnaud Giersch [Thu, 3 Jun 2021 07:38:57 +0000 (09:38 +0200)]
Use existing function (also empties requests_ after waitall).

2 years agoImprove debug messages and avoid calling finish_comms twice when for myself.
Arnaud Giersch [Thu, 3 Jun 2021 07:37:39 +0000 (09:37 +0200)]
Improve debug messages and avoid calling finish_comms twice when for myself.

2 years agoInitialize variable.
Arnaud Giersch [Thu, 3 Jun 2021 07:23:48 +0000 (09:23 +0200)]
Initialize variable.

2 years agoUse existing functions to finish comms (and fix Win::flush).
Arnaud Giersch [Wed, 2 Jun 2021 15:38:03 +0000 (17:38 +0200)]
Use existing functions to finish comms (and fix Win::flush).

2 years agoReview usage of rank/rank_/rank() is smpi_win.
Arnaud Giersch [Wed, 2 Jun 2021 15:10:47 +0000 (17:10 +0200)]
Review usage of rank/rank_/rank() is smpi_win.

2 years agoLittle simplifications in loops.
Arnaud Giersch [Wed, 2 Jun 2021 14:37:24 +0000 (16:37 +0200)]
Little simplifications in loops.

2 years agoSome int -> bool conversions (+ use of existing macro).
Arnaud Giersch [Wed, 2 Jun 2021 12:55:46 +0000 (14:55 +0200)]
Some int -> bool conversions (+ use of existing macro).

2 years agoCall rank() only once.
Arnaud Giersch [Wed, 2 Jun 2021 11:49:30 +0000 (13:49 +0200)]
Call rank() only once.

2 years agoOoops, fmt is second arg.
Arnaud Giersch [Wed, 2 Jun 2021 10:23:02 +0000 (12:23 +0200)]
Ooops, fmt is second arg.

2 years agoPrefer emplace_back.
Arnaud Giersch [Wed, 2 Jun 2021 09:09:14 +0000 (11:09 +0200)]
Prefer emplace_back.

2 years agoGet rid of "%s" in second argument of function xbt_str_parse_*.
Arnaud Giersch [Wed, 2 Jun 2021 09:05:48 +0000 (11:05 +0200)]
Get rid of "%s" in second argument of function xbt_str_parse_*.

2 years agoXBT_ATTRIB_PRINTF for vprintf-like functions.
Arnaud Giersch [Wed, 2 Jun 2021 08:45:13 +0000 (10:45 +0200)]
XBT_ATTRIB_PRINTF for vprintf-like functions.

2 years agoDefine class SmpiBenchGuard, and use RAII to handle smpi_bench_end()/smpi_bench_begin().
Arnaud Giersch [Wed, 2 Jun 2021 08:15:28 +0000 (10:15 +0200)]
Define class SmpiBenchGuard, and use RAII to handle smpi_bench_end()/smpi_bench_begin().

2 years agoAdd missing calls to smpi_bench_begin() on error paths.
Arnaud Giersch [Tue, 1 Jun 2021 20:45:17 +0000 (22:45 +0200)]
Add missing calls to smpi_bench_begin() on error paths.

2 years agoCannot set split-duplex through s4u intf.
Bruno Donassolo [Tue, 1 Jun 2021 15:48:47 +0000 (17:48 +0200)]
Cannot set split-duplex through s4u intf.

This makes sense only in XML where it properly creates the
link-up/link-down.

2 years agoAdd fg#71 to changelog [ci-skip]
Bruno Donassolo [Tue, 1 Jun 2021 15:48:18 +0000 (17:48 +0200)]
Add fg#71 to changelog [ci-skip]

2 years agoMissing include.
Arnaud Giersch [Tue, 1 Jun 2021 13:51:01 +0000 (15:51 +0200)]
Missing include.

2 years agoCoding style: no global "using namespace".
Arnaud Giersch [Tue, 1 Jun 2021 13:30:44 +0000 (15:30 +0200)]
Coding style: no global "using namespace".

2 years agoPrefer std algorithms.
Arnaud Giersch [Tue, 1 Jun 2021 13:26:10 +0000 (15:26 +0200)]
Prefer std algorithms.

2 years agoInvert tests to reduce depth of nesting.
Arnaud Giersch [Tue, 1 Jun 2021 12:53:37 +0000 (14:53 +0200)]
Invert tests to reduce depth of nesting.

2 years agoUseless tests for emptyness.
Arnaud Giersch [Tue, 1 Jun 2021 12:50:07 +0000 (14:50 +0200)]
Useless tests for emptyness.

2 years agoAdd attribute(printf) to xbt::string_printf.
Arnaud Giersch [Tue, 1 Jun 2021 10:59:34 +0000 (12:59 +0200)]
Add attribute(printf) to xbt::string_printf.

2 years agoPointer-to-const for Sonar.
Arnaud Giersch [Tue, 1 Jun 2021 07:38:57 +0000 (09:38 +0200)]
Pointer-to-const for Sonar.

2 years agoSet shared variable *before* mutex unlock.
Arnaud Giersch [Mon, 31 May 2021 21:20:24 +0000 (23:20 +0200)]
Set shared variable *before* mutex unlock.

2 years agoDie on unwanted function calls.
Arnaud Giersch [Mon, 31 May 2021 21:01:42 +0000 (23:01 +0200)]
Die on unwanted function calls.

2 years agoParameter 'assert' is a bit field.
Arnaud Giersch [Mon, 31 May 2021 20:53:55 +0000 (22:53 +0200)]
Parameter 'assert' is a bit field.

2 years agoFixes in UTs
Bruno Donassolo [Mon, 31 May 2021 17:22:28 +0000 (19:22 +0200)]
Fixes in UTs

2 years agoHandle case where different groups are given to MPI_Win_start and MPI_Win_post on...
Arnaud Giersch [Mon, 31 May 2021 13:40:40 +0000 (15:40 +0200)]
Handle case where different groups are given to MPI_Win_start and MPI_Win_post on a seame process.

2 years agoHandle duplicated datatypes within predefined MPI_Op.
Arnaud Giersch [Mon, 31 May 2021 13:14:10 +0000 (15:14 +0200)]
Handle duplicated datatypes within predefined MPI_Op.

2 years agoDocker: try to get apt update to run despite the cache
Martin Quinson [Mon, 31 May 2021 10:33:06 +0000 (12:33 +0200)]
Docker: try to get apt update to run despite the cache

2 years agoA few more 'const'.
Arnaud Giersch [Mon, 31 May 2021 09:32:23 +0000 (11:32 +0200)]
A few more 'const'.

2 years agoReplace redundant type with 'auto'.
Arnaud Giersch [Mon, 31 May 2021 09:28:24 +0000 (11:28 +0200)]
Replace redundant type with 'auto'.

2 years agoRemove useless temporary shadowing outer variable.
Arnaud Giersch [Mon, 31 May 2021 09:24:54 +0000 (11:24 +0200)]
Remove useless temporary shadowing outer variable.

2 years agoAdd some 'const' qualifiers.
Arnaud Giersch [Mon, 31 May 2021 08:22:02 +0000 (10:22 +0200)]
Add some 'const' qualifiers.

This started with NetPoint::get_englobing_zone() and propagated quickly...

2 years agoUnused exception parameter 'e'.
Arnaud Giersch [Mon, 31 May 2021 07:44:22 +0000 (09:44 +0200)]
Unused exception parameter 'e'.

2 years agoExplicitly delete the copy constructor and copy assignment operator (enforce rule...
Arnaud Giersch [Mon, 31 May 2021 07:40:15 +0000 (09:40 +0200)]
Explicitly delete the copy constructor and copy assignment operator (enforce rule-of-five).

2 years agoNo valgrind leak check for issue71.
Arnaud Giersch [Sat, 29 May 2021 12:25:53 +0000 (14:25 +0200)]
No valgrind leak check for issue71.

2 years agoxbt_replay: rethrow exception instead of xbt_die
Millian Poquet [Fri, 28 May 2021 21:03:01 +0000 (23:03 +0200)]
xbt_replay: rethrow exception instead of xbt_die

2 years agoRemove sg_bandwidth_factor from disks
Bruno Donassolo [Fri, 28 May 2021 19:16:55 +0000 (21:16 +0200)]
Remove sg_bandwidth_factor from disks

No need for bw_factor here

2 years agoremove a space to force update
Lucas M. Schnorr [Fri, 28 May 2021 19:10:50 +0000 (16:10 -0300)]
remove a space to force update

2 years agoIssue#71: add check in add_route for gw_src/gw_dst
Bruno Donassolo [Fri, 28 May 2021 17:49:45 +0000 (19:49 +0200)]
Issue#71: add check in add_route for gw_src/gw_dst

When adding a NetZoneRoute, check if gw_src and gw_dst belongs to the
respective netzones.

We need to recursively search for the netpoint inside the netzone since
the netpoint can be from one of its children.

2 years agoFix refcount for Datatype_contents.
Arnaud Giersch [Fri, 28 May 2021 15:16:30 +0000 (17:16 +0200)]
Fix refcount for Datatype_contents.

Error seen with Petsc test: vec_is_sf_tutorials-ex3_basic_dupped.

2 years agoAllow null ranks for MPI_Group_incl when n == 0.
Arnaud Giersch [Fri, 28 May 2021 09:52:30 +0000 (11:52 +0200)]
Allow null ranks for MPI_Group_incl when n == 0.

2 years agoupdate draw_gantt.R script to work with pajengr
Lucas M. Schnorr [Fri, 28 May 2021 14:48:12 +0000 (11:48 -0300)]
update draw_gantt.R script to work with pajengr

todo
- need to test with a recent version of S4U trace

2 years agoupdate pajengr installation procedure in S4U tutorial
Lucas M. Schnorr [Fri, 28 May 2021 14:41:29 +0000 (11:41 -0300)]
update pajengr installation procedure in S4U tutorial

2 years agoreplace r-cran-dplyr by r-cran-devtools
Lucas M. Schnorr [Fri, 28 May 2021 14:36:59 +0000 (11:36 -0300)]
replace r-cran-dplyr by r-cran-devtools

2 years agoupdate tuto-smpi Dockerfile to contain r-cran-tidyverse (replacing included R packages)
Lucas M. Schnorr [Fri, 28 May 2021 14:35:35 +0000 (11:35 -0300)]
update tuto-smpi Dockerfile to contain r-cran-tidyverse (replacing included R packages)

2 years agoadd additional necessary packages for pajengr installation
Lucas M. Schnorr [Fri, 28 May 2021 14:26:40 +0000 (11:26 -0300)]
add additional necessary packages for pajengr installation

2 years agoupdate pajengr R code and figure
Lucas M. Schnorr [Fri, 28 May 2021 13:56:14 +0000 (10:56 -0300)]
update pajengr R code and figure

details:
- note the addition of library(tidyverse)

2 years agouse new option in random test.
Augustin Degomme [Thu, 27 May 2021 14:55:48 +0000 (16:55 +0200)]
use new option in random test.

2 years agodocument new option
Augustin Degomme [Thu, 27 May 2021 14:47:48 +0000 (16:47 +0200)]
document new option

2 years agoAdd flag to provide an optional barrier in MPI_Finalize.
Augustin Degomme [Thu, 27 May 2021 13:40:44 +0000 (15:40 +0200)]
Add flag to provide an optional barrier in MPI_Finalize.
This is meant to help for codes which can aggressively cleanup memory at finalization, while other processes still have to use it.
For example when attributes are attached to a local communicator, in SMPI this communicator may be cleaned up by another process in the end, and the attribute has to still be valid at this point.
This was an issue with PETSC, for example.

2 years agoUse std::string for xbt_parse_units.
Arnaud Giersch [Thu, 27 May 2021 09:04:25 +0000 (11:04 +0200)]
Use std::string for xbt_parse_units.

Combine parameters 'entity_kind' and 'name'.
Also rename surf_parse_* to xbt_parse_*.

2 years agoDeprecate SIMIX_get_clock().
Arnaud Giersch [Thu, 27 May 2021 08:35:46 +0000 (10:35 +0200)]
Deprecate SIMIX_get_clock().

Use simgrid_get_clock() or Engine::get_clock().

2 years agoKeyval should always exist.
Arnaud Giersch [Thu, 27 May 2021 07:52:59 +0000 (09:52 +0200)]
Keyval should always exist.

Also please sonar by reducing depth for nested blocks.

2 years agoleaks analysis: when -analyze is given to smpirun, set value for list-leaks to 50.
Augustin Degomme [Thu, 27 May 2021 09:13:29 +0000 (11:13 +0200)]
leaks analysis: when -analyze is given to smpirun, set value for list-leaks to 50.

2 years agoleaks analysis : activate if list-leaks is asked manually (without smpi/display-alloc...
Augustin Degomme [Thu, 27 May 2021 09:12:17 +0000 (11:12 +0200)]
leaks analysis : activate if list-leaks is asked manually (without smpi/display-allocs or -analyze)

2 years agomake simix_global->maestro_ private
SUTER Frederic [Wed, 26 May 2021 14:39:49 +0000 (16:39 +0200)]
make simix_global->maestro_ private

2 years agoCheck types matching in MPI communications.
Augustin Degomme [Wed, 26 May 2021 14:49:56 +0000 (16:49 +0200)]
Check types matching in MPI communications.
should work with basic ones and duplicated ones.
todo: derived types matching, which is more tricky.

2 years agomark these as derived datatypes, and don't divide by 0 if possible
Augustin Degomme [Wed, 26 May 2021 14:48:09 +0000 (16:48 +0200)]
mark these as derived datatypes, and don't divide by 0 if possible

2 years agokeep track of which datatype was duplicated, to be able to match with it later
Augustin Degomme [Wed, 26 May 2021 14:47:22 +0000 (16:47 +0200)]
keep track of which datatype was duplicated, to be able to match with it later

2 years agonothing old here, just the type ..
Augustin Degomme [Wed, 26 May 2021 09:44:45 +0000 (11:44 +0200)]
nothing old here, just the type ..

2 years agoprepare transition of context_factory: make it private
SUTER Frederic [Wed, 26 May 2021 10:37:29 +0000 (12:37 +0200)]
prepare transition of context_factory: make it private

2 years agoMinor simplification in CM02::communicate
Bruno Donassolo [Wed, 26 May 2021 10:17:33 +0000 (12:17 +0200)]
Minor simplification in CM02::communicate

Don't need a function in NetworkModel for an "if" used only in CM02

2 years agoFix potential mem leak seen by scan-build.
Arnaud Giersch [Wed, 26 May 2021 07:30:23 +0000 (09:30 +0200)]
Fix potential mem leak seen by scan-build.

Note that ret should not normally be different than MPI_SUCCESS in the other case.

2 years agoDon't create mailbox before engine is turned on.
Arnaud Giersch [Tue, 25 May 2021 15:46:43 +0000 (17:46 +0200)]
Don't create mailbox before engine is turned on.

2 years agoLookup only once on mailbox creation.
Arnaud Giersch [Tue, 25 May 2021 14:58:42 +0000 (16:58 +0200)]
Lookup only once on mailbox creation.

2 years agoMisc sonar smells.
Arnaud Giersch [Tue, 25 May 2021 14:21:20 +0000 (16:21 +0200)]
Misc sonar smells.

2 years agovector::back() is good enough + assert for scan_build.
Arnaud Giersch [Tue, 25 May 2021 14:17:20 +0000 (16:17 +0200)]
vector::back() is good enough + assert for scan_build.

2 years ago[cppcheck] Don't let fields uninitialized.
Arnaud Giersch [Thu, 6 May 2021 18:21:59 +0000 (20:21 +0200)]
[cppcheck] Don't let fields uninitialized.

2 years ago[sonar] Extract assignments from expressions.
Arnaud Giersch [Thu, 6 May 2021 13:49:55 +0000 (15:49 +0200)]
[sonar] Extract assignments from expressions.

2 years agoPlug remaining leaks in mpich3-test/f77/attr.
Arnaud Giersch [Sun, 23 May 2021 22:20:38 +0000 (00:20 +0200)]
Plug remaining leaks in mpich3-test/f77/attr.

2 years agoPlug memleaks with Fortran bindings.
Arnaud Giersch [Sun, 23 May 2021 20:40:39 +0000 (22:40 +0200)]
Plug memleaks with Fortran bindings.

2 years agoReview allocation of MPI attributes with Fortran bindings.
Arnaud Giersch [Sun, 23 May 2021 20:26:58 +0000 (22:26 +0200)]
Review allocation of MPI attributes with Fortran bindings.

2 years agoFix refcounting of MPI keyvals when keyval_free is called twice.
Arnaud Giersch [Tue, 25 May 2021 12:33:56 +0000 (14:33 +0200)]
Fix refcounting of MPI keyvals when keyval_free is called twice.

2 years agoSimplify a bit Keyval::attr_delete.
Arnaud Giersch [Tue, 25 May 2021 12:23:59 +0000 (14:23 +0200)]
Simplify a bit Keyval::attr_delete.

2 years agoDon't increase refcount when existing elem is overwritten.
Arnaud Giersch [Sat, 22 May 2021 20:15:05 +0000 (22:15 +0200)]
Don't increase refcount when existing elem is overwritten.