mirror of
https://gitlab.com/scemama/QCaml.git
synced 2024-07-25 12:17:25 +02:00
Initiated parallel
This commit is contained in:
parent
883e369b4e
commit
408b7692a6
@ -1,6 +1,6 @@
|
|||||||
.NOPARALLEL:
|
.NOPARALLEL:
|
||||||
|
|
||||||
INCLUDE_DIRS=Nuclei,Utils,Basis,SCF,MOBasis,CI
|
INCLUDE_DIRS=Parallel,Nuclei,Utils,Basis,SCF,MOBasis,CI
|
||||||
LIBS=
|
LIBS=
|
||||||
PKGS=
|
PKGS=
|
||||||
OCAMLBUILD=ocamlbuild -j 0 -cflags $(ocamlcflags) -lflags $(ocamlcflags) $(ocamldocflags) -Is $(INCLUDE_DIRS) -ocamlopt $(ocamloptflags)
|
OCAMLBUILD=ocamlbuild -j 0 -cflags $(ocamlcflags) -lflags $(ocamlcflags) $(ocamldocflags) -Is $(INCLUDE_DIRS) -ocamlopt $(ocamloptflags)
|
||||||
|
6
Parallel/Parallel.ml
Normal file
6
Parallel/Parallel.ml
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
(** Module for handling distributed parallelism *)
|
||||||
|
|
||||||
|
let size = Mpi.comm_size Mpi.comm_world
|
||||||
|
let rank = Mpi.comm_rank Mpi.comm_world
|
||||||
|
|
||||||
|
|
10
Parallel/Parallel.mli
Normal file
10
Parallel/Parallel.mli
Normal file
@ -0,0 +1,10 @@
|
|||||||
|
(** Module for handling distributed parallelism *)
|
||||||
|
|
||||||
|
val size : int
|
||||||
|
(** Number of distributed processes. *)
|
||||||
|
|
||||||
|
val rank : Mpi.rank
|
||||||
|
(** Rannk of the current distributed processe. *)
|
||||||
|
|
||||||
|
|
||||||
|
|
2
_tags
2
_tags
@ -1,4 +1,4 @@
|
|||||||
true: package(str,unix,bigarray,lacaml,alcotest,zarith)
|
true: package(str,unix,bigarray,lacaml,alcotest,zarith,mpi)
|
||||||
<*.byte> : linkdep(Utils/math_functions.o), custom
|
<*.byte> : linkdep(Utils/math_functions.o), custom
|
||||||
<*.native>: linkdep(Utils/math_functions.o)
|
<*.native>: linkdep(Utils/math_functions.o)
|
||||||
<odoc-ltxhtml>: not_hygienic
|
<odoc-ltxhtml>: not_hygienic
|
||||||
|
5
run_parallel.ml
Normal file
5
run_parallel.ml
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
|
||||||
|
let () =
|
||||||
|
Printf.printf "Hello from rank %d of %d.\n"
|
||||||
|
Parallel.rank Parallel.size
|
||||||
|
|
Loading…
Reference in New Issue
Block a user