Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
O
openfpm_pdata
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
1
Issues
1
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
Requirements
Requirements
List
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Operations
Operations
Environments
Analytics
Analytics
CI / CD
Code Review
Insights
Issue
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
openfpm
openfpm_pdata
Commits
544e4014
Commit
544e4014
authored
Mar 02, 2016
by
tonynsyde
Browse files
Options
Browse Files
Download
Plain Diff
Fixing and merging
parents
6b9ab5c7
8eb4ab81
Changes
106
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
106 changed files
with
12538 additions
and
2342 deletions
+12538
-2342
.gitignore
.gitignore
+74
-0
.gitmodules
.gitmodules
+5
-5
CHANGELOG.md
CHANGELOG.md
+33
-0
Makefile.am
Makefile.am
+1
-1
build_pdata.sh
build_pdata.sh
+10
-11
configure.ac
configure.ac
+97
-20
example/Grid/0_simple/main.cpp
example/Grid/0_simple/main.cpp
+13
-12
example/Grid/1_stencil/main.cpp
example/Grid/1_stencil/main.cpp
+23
-18
example/Numerics/Makefile
example/Numerics/Makefile
+11
-0
example/Numerics/PSE/0_Derivative_approx_1D/Makefile
example/Numerics/PSE/0_Derivative_approx_1D/Makefile
+21
-0
example/Numerics/PSE/0_Derivative_approx_1D/main.cpp
example/Numerics/PSE/0_Derivative_approx_1D/main.cpp
+309
-0
example/Numerics/PSE/Makefile
example/Numerics/PSE/Makefile
+11
-0
example/SE/0_classes/Makefile
example/SE/0_classes/Makefile
+21
-0
example/SE/0_classes/config.cfg
example/SE/0_classes/config.cfg
+2
-0
example/SE/0_classes/main.cpp
example/SE/0_classes/main.cpp
+211
-0
example/SE/1_classes/Makefile
example/SE/1_classes/Makefile
+21
-0
example/SE/1_classes/config.cfg
example/SE/1_classes/config.cfg
+2
-0
example/SE/1_classes/main.cpp
example/SE/1_classes/main.cpp
+109
-0
example/SE/Makefile
example/SE/Makefile
+11
-0
example/VCluster/0_simple/Makefile
example/VCluster/0_simple/Makefile
+21
-0
example/VCluster/0_simple/config.cfg
example/VCluster/0_simple/config.cfg
+2
-0
example/VCluster/0_simple/main.cpp
example/VCluster/0_simple/main.cpp
+177
-0
example/VCluster/Makefile
example/VCluster/Makefile
+11
-0
example/Vector/0_simple/Makefile
example/Vector/0_simple/Makefile
+3
-3
example/Vector/0_simple/main.cpp
example/Vector/0_simple/main.cpp
+50
-7
example/Vector/1_celllist/config.cfg
example/Vector/1_celllist/config.cfg
+2
-0
example/Vector/1_celllist/main.cpp
example/Vector/1_celllist/main.cpp
+181
-0
example/Vector/1_verlet/config.cfg
example/Vector/1_verlet/config.cfg
+2
-0
example/Vector/1_verlet/main.cpp
example/Vector/1_verlet/main.cpp
+179
-0
install
install
+87
-37
m4/ax_blas.m4
m4/ax_blas.m4
+239
-0
m4/ax_boost.m4
m4/ax_boost.m4
+0
-523
m4/ax_boost_base.m4
m4/ax_boost_base.m4
+286
-0
m4/ax_boost_iostreams.m4
m4/ax_boost_iostreams.m4
+119
-0
m4/ax_boost_program_options.m4
m4/ax_boost_program_options.m4
+110
-0
m4/ax_boost_unit_test_framework.m4
m4/ax_boost_unit_test_framework.m4
+139
-0
m4/ax_eigen.m4
m4/ax_eigen.m4
+87
-0
m4/ax_lapack.m4
m4/ax_lapack.m4
+132
-0
m4/ax_suitesparse.m4
m4/ax_suitesparse.m4
+131
-0
openfpm_data
openfpm_data
+1
-1
openfpm_pdata.doc
openfpm_pdata.doc
+3
-3
script/detect_fortran
script/detect_fortran
+16
-0
script/detect_gcc
script/detect_gcc
+11
-8
script/discover_os
script/discover_os
+0
-2
script/discover_package_manager
script/discover_package_manager
+2
-3
script/install_BOOST.sh
script/install_BOOST.sh
+4
-3
script/install_EIGEN.sh
script/install_EIGEN.sh
+20
-0
script/install_MPI.sh
script/install_MPI.sh
+14
-0
script/install_OPENBLAS.sh
script/install_OPENBLAS.sh
+21
-0
script/install_SUITESPARSE.sh
script/install_SUITESPARSE.sh
+60
-0
script/pre_req
script/pre_req
+67
-6
script/remove_old
script/remove_old
+89
-0
script/solve_gfortran
script/solve_gfortran
+26
-0
script/solve_gpp
script/solve_gpp
+8
-0
src/DLB/DLB.hpp
src/DLB/DLB.hpp
+0
-0
src/DLB/DLB_unit_test.hpp
src/DLB/DLB_unit_test.hpp
+0
-0
src/Decomposition/CartDecomposition.hpp
src/Decomposition/CartDecomposition.hpp
+822
-153
src/Decomposition/CartDecomposition_unit_test.hpp
src/Decomposition/CartDecomposition_unit_test.hpp
+253
-50
src/Decomposition/Distribution/DistParMetisDistribution.hpp
src/Decomposition/Distribution/DistParMetisDistribution.hpp
+31
-3
src/Decomposition/Distribution/Distribution_unit_tests.hpp
src/Decomposition/Distribution/Distribution_unit_tests.hpp
+246
-0
src/Decomposition/Distribution/MetisDistribution.hpp
src/Decomposition/Distribution/MetisDistribution.hpp
+499
-0
src/Decomposition/Distribution/ParMetisDistribution.hpp
src/Decomposition/Distribution/ParMetisDistribution.hpp
+246
-219
src/Decomposition/Distribution/metis_util.hpp
src/Decomposition/Distribution/metis_util.hpp
+32
-6
src/Decomposition/Distribution/metis_util_unit_test.hpp
src/Decomposition/Distribution/metis_util_unit_test.hpp
+29
-5
src/Decomposition/Distribution/parmetis_dist_util.hpp
src/Decomposition/Distribution/parmetis_dist_util.hpp
+1
-1
src/Decomposition/Distribution/parmetis_util.hpp
src/Decomposition/Distribution/parmetis_util.hpp
+162
-135
src/Decomposition/MetisDistribution.hpp
src/Decomposition/MetisDistribution.hpp
+0
-254
src/Decomposition/common.hpp
src/Decomposition/common.hpp
+144
-11
src/Decomposition/ie_ghost.hpp
src/Decomposition/ie_ghost.hpp
+478
-42
src/Decomposition/ie_loc_ghost.hpp
src/Decomposition/ie_loc_ghost.hpp
+377
-28
src/Decomposition/nn_processor.hpp
src/Decomposition/nn_processor.hpp
+319
-48
src/Decomposition/nn_processor_unit_test.hpp
src/Decomposition/nn_processor_unit_test.hpp
+228
-0
src/Graph/CartesianGraphFactory.hpp
src/Graph/CartesianGraphFactory.hpp
+24
-30
src/Graph/CartesianGraphFactory_unit_test.hpp
src/Graph/CartesianGraphFactory_unit_test.hpp
+35
-2
src/Graph/DistCartesianGraphFactory.hpp
src/Graph/DistCartesianGraphFactory.hpp
+3
-3
src/Graph/DistCartesianGraphFactory_unit_test.hpp
src/Graph/DistCartesianGraphFactory_unit_test.hpp
+25
-21
src/Graph/dist_map_graph.hpp
src/Graph/dist_map_graph.hpp
+4
-2
src/Graph/ids.hpp
src/Graph/ids.hpp
+130
-0
src/Grid/grid_dist_id.hpp
src/Grid/grid_dist_id.hpp
+571
-103
src/Grid/grid_dist_id_iterator.hpp
src/Grid/grid_dist_id_iterator.hpp
+39
-27
src/Grid/grid_dist_id_iterator_dec.hpp
src/Grid/grid_dist_id_iterator_dec.hpp
+262
-0
src/Grid/grid_dist_id_iterator_sub.hpp
src/Grid/grid_dist_id_iterator_sub.hpp
+254
-0
src/Grid/grid_dist_id_unit_test.hpp
src/Grid/grid_dist_id_unit_test.hpp
+675
-16
src/Grid/grid_dist_id_unit_test_ext_dom.hpp
src/Grid/grid_dist_id_unit_test_ext_dom.hpp
+100
-0
src/Grid/grid_dist_key.hpp
src/Grid/grid_dist_key.hpp
+41
-1
src/Grid/grid_dist_util.hpp
src/Grid/grid_dist_util.hpp
+86
-0
src/Grid/staggered_dist_grid.hpp
src/Grid/staggered_dist_grid.hpp
+137
-0
src/Grid/staggered_dist_grid_util.hpp
src/Grid/staggered_dist_grid_util.hpp
+661
-0
src/Grid/staggered_grid_dist_unit_test.hpp
src/Grid/staggered_grid_dist_unit_test.hpp
+60
-0
src/Makefile.am
src/Makefile.am
+10
-5
src/SubdomainGraphNodes.hpp
src/SubdomainGraphNodes.hpp
+7
-25
src/Vector/vector_dist.hpp
src/Vector/vector_dist.hpp
+898
-377
src/Vector/vector_dist_iterator.hpp
src/Vector/vector_dist_iterator.hpp
+7
-44
src/Vector/vector_dist_key.hpp
src/Vector/vector_dist_key.hpp
+11
-11
src/Vector/vector_dist_ofb.hpp
src/Vector/vector_dist_ofb.hpp
+78
-0
src/Vector/vector_dist_unit_test.hpp
src/Vector/vector_dist_unit_test.hpp
+850
-24
src/dec_optimizer.hpp
src/dec_optimizer.hpp
+16
-10
src/dec_optimizer_unit_test.hpp
src/dec_optimizer_unit_test.hpp
+98
-10
src/gargabe.hpp
src/gargabe.hpp
+232
-0
src/lib/pdata.cpp
src/lib/pdata.cpp
+16
-0
src/main.cpp
src/main.cpp
+5
-2
src/test_multiple_o.cpp
src/test_multiple_o.cpp
+35
-0
vtk/CartDecomposition_gen_vtk.cpp
vtk/CartDecomposition_gen_vtk.cpp
+4
-1
vtk/Makefile.am
vtk/Makefile.am
+6
-6
vtk/Metis_gen_vtk.cpp
vtk/Metis_gen_vtk.cpp
+5
-3
vtk/domain_gen_vtk.cpp
vtk/domain_gen_vtk.cpp
+1
-1
No files found.
.gitignore
0 → 100644
View file @
544e4014
# Compiled source #
###################
*.com
*.class
*.dll
*.exe
*.o
*.so
# Packages #
############
# it's better to unpack these files and commit the raw source
# git has its own built in compression methods
*.7z
*.dmg
*.gz
*.iso
*.jar
*.rar
*.tar
*.zip
# Logs and databases #
######################
*.log
*.sql
*.sqlite
# OS generated files #
######################
.DS_Store
.DS_Store?
._*
.Spotlight-V100
.Trashes
ehthumbs.db
Thumbs.db
###### Other
*.vtk
AUTHORS
COPYING
INSTALL
NEWS
README
**/vtk/Makefile
**/src/Makefile
./Makefile
Makefile.in
config.status
configure
numerics
**/.deps
**/src/config
aclocal.m4
**/autom4te.cache
example.mk
src/pdata
vtk/cart_dec
vtk/dom_box
vtk/metis_dec
.autotools
.cproject
.project
.settings
ar-lib
compile
config.guess
config.sub
depcomp
install-sh
missing
install_dir
.gitmodules
View file @
544e4014
[submodule "openfpm_vcluster"]
path = openfpm_vcluster
url = ssh://git@ppmcore.mpi-cbg.de
:
/incardon/openfpm_vcluster.git
url = ssh://git@ppmcore.mpi-cbg.de/incardon/openfpm_vcluster.git
[submodule "openfpm_devices"]
path = openfpm_devices
url = ssh://git@ppmcore.mpi-cbg.de
:
/incardon/openfpm_devices.git
url = ssh://git@ppmcore.mpi-cbg.de/incardon/openfpm_devices.git
[submodule "openfpm_io"]
path = openfpm_io
url = ssh://git@ppmcore.mpi-cbg.de
:
/incardon/openfpm_io.git
url = ssh://git@ppmcore.mpi-cbg.de/incardon/openfpm_io.git
[submodule "openfpm_data"]
path = openfpm_data
url = ssh://git@ppmcore.mpi-cbg.de
:
/incardon/openfpm_data.git
url = ssh://git@ppmcore.mpi-cbg.de/incardon/openfpm_data.git
[submodule "openfpm_numerics"]
path = openfpm_numerics
url = ssh://git@ppmcore.mpi-cbg.de
:
/incardon/openfpm_numerics.git
url = ssh://git@ppmcore.mpi-cbg.de/incardon/openfpm_numerics.git
CHANGELOG.md
0 → 100644
View file @
544e4014
# Change Log
All notable changes to this project will be documented in this file.
## [0.2.0] - 2015-02-17
### Added
-
PSE 1D example with multiple precision
-
Plot example for GoogleChart plotting
-
Distributed data structure now support 128bit floating point precision (on Beta)
-
OpenFPM support for Microsoft Windows (Cygwin) compilation
### Fixed
-
Detection 32 bit system and report as an error
### Changed
-
Nothing to report
## [0.1.0] - 2015-02-05
### Added
-
PSE 1D example
-
Cell list example
-
Verlet list example
-
Kickstart for OpenFPM_numeric
-
Automated dependency installation for SUITESPRASE EIGEN OPENBLAS(LAPACK)
### Fixed
-
CRITICAL BUG in periodic bondary condition
-
BOOST auto updated to 1.60
-
Compilation with multiple .cpp files
### Changed
-
Nothing to report
Makefile.am
View file @
544e4014
SUBDIRS
=
src vtk openfpm_data openfpm_io openfpm_devices openfpm_vcluster
SUBDIRS
=
src vtk openfpm_data openfpm_io openfpm_devices openfpm_vcluster
openfpm_numerics
bin_PROGRAMS
=
build_pdata.sh
View file @
544e4014
#! /bin/bash
# Make a directory in /tmp/OpenFPM_data
# Make a directory in /tmp/OpenFPM_
p
data
echo
"Directory:
$1
"
echo
"Machine:
$2
"
...
...
@@ -19,6 +19,8 @@ if [ $? -ne 0 ]; then
exit
1
fi
mkdir
openfpm_numerics/src/config
# pull from all the projects
cd
openfpm_data
git checkout develop
...
...
@@ -57,12 +59,10 @@ if [ $? -ne 0 ]; then
fi
cd
..
if
[
"
$2
"
==
"gin"
]
then
echo
"Compiling on gin
\n
"
source
~/.bashrc
sh ./autogen.sh
module load gcc/4.9.2
./install
-s
-c
"--prefix=/home/jenkins/openfpm_install"
make
...
...
@@ -218,38 +218,38 @@ then
module load boost/1.56.0-gnu4.9.1
module unload gcc/4.9.1
module load gcc/4.9.3
module load openmpi/1.8.
7
module load openmpi/1.8.
8-gnu
module unload bullxmpi
module load metis/5.1.0
./install
-s
-c
"--with-metis=
$METIS_ROOT
--with-boost=
$BOOST_ROOT
CXX=mpic++"
./install
-s
-c
"--with-metis=
/sw/global/libraries/metis/5.1.0/x86_64/ --with-boost=/sw/taurus/libraries/boost/1.56.0-gnu4.9.1
CXX=mpic++"
make
if
[
$?
-ne
0
]
;
then
curl
-X
POST
--data
"payload={
\"
icon_emoji
\"
:
\"
:jenkins:
\"
,
\"
username
\"
:
\"
jenkins
\"
,
\"
attachments
\"
:[{
\"
title
\"
:
\"
Error:
\"
,
\"
color
\"
:
\"
#FF0000
\"
,
\"
text
\"
:
\"
$2
failed to complete the openfpm_pdata test
\"
}] }"
https://hooks.slack.com/services/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
exit
1
;
fi
salloc
--nodes
=
1
--ntasks-per-node
=
16
--time
=
00:10:00
--mem-per-cpu
=
1900
--partition
=
haswell bash
-c
"ulimit -s unlimited && mpirun -np 16 src/pdata
"
salloc
--nodes
=
1
--ntasks-per-node
=
24
--exclude
=
taurusi[6300-6400],taurusi[5400-5500]
--time
=
00:5:00
--mem-per-cpu
=
1900
--partition
=
haswell bash
-c
"ulimit -s unlimited && mpirun -np 24 src/pdata --report_level=no
"
if
[
$?
-ne
0
]
;
then
curl
-X
POST
--data
"payload={
\"
icon_emoji
\"
:
\"
:jenkins:
\"
,
\"
username
\"
:
\"
jenkins
\"
,
\"
attachments
\"
:[{
\"
title
\"
:
\"
Error:
\"
,
\"
color
\"
:
\"
#FF0000
\"
,
\"
text
\"
:
\"
$2
failed to complete the openfpm_pdata test
\"
}] }"
https://hooks.slack.com/services/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
exit
1
;
fi
salloc
--nodes
=
2
--ntasks-per-node
=
16
--time
=
00:10:00
--mem-per-cpu
=
1900
--partition
=
haswell bash
-c
"ulimit -s unlimited && mpirun -np 32 src/pdata
"
salloc
--nodes
=
2
--ntasks-per-node
=
24
--exclude
=
taurusi[6300-6400],taurusi[5400-5500]
--time
=
00:5:00
--mem-per-cpu
=
1900
--partition
=
haswell bash
-c
"ulimit -s unlimited && mpirun -np 48 src/pdata --report_level=no
"
if
[
$?
-ne
0
]
;
then
curl
-X
POST
--data
"payload={
\"
icon_emoji
\"
:
\"
:jenkins:
\"
,
\"
username
\"
:
\"
jenkins
\"
,
\"
attachments
\"
:[{
\"
title
\"
:
\"
Error:
\"
,
\"
color
\"
:
\"
#FF0000
\"
,
\"
text
\"
:
\"
$2
failed to complete the openfpm_pdata test
\"
}] }"
https://hooks.slack.com/services/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
exit
1
;
fi
salloc
--nodes
=
4
--ntasks-per-node
=
16
--time
=
00:10:00
--mem-per-cpu
=
1900
--partition
=
haswell bash
-c
"ulimit -s unlimited && mpirun -np 64 src/pdata
"
salloc
--nodes
=
4
--ntasks-per-node
=
24
--exclude
=
taurusi[6300-6400],taurusi[5400-5500]
--time
=
00:5:00
--mem-per-cpu
=
1900
--partition
=
haswell bash
-c
"ulimit -s unlimited && mpirun -np 96 src/pdata --report_level=no
"
if
[
$?
-ne
0
]
;
then
curl
-X
POST
--data
"payload={
\"
icon_emoji
\"
:
\"
:jenkins:
\"
,
\"
username
\"
:
\"
jenkins
\"
,
\"
attachments
\"
:[{
\"
title
\"
:
\"
Error:
\"
,
\"
color
\"
:
\"
#FF0000
\"
,
\"
text
\"
:
\"
$2
failed to complete the openfpm_pdata test
\"
}] }"
https://hooks.slack.com/services/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
exit
1
;
fi
salloc
--nodes
=
8
--ntasks-per-node
=
16
--time
=
00:10:00
--mem-per-cpu
=
1900
--partition
=
haswell bash
-c
"ulimit -s unlimited && mpirun -np 128 src/pdata
"
salloc
--nodes
=
8
--ntasks-per-node
=
24
--exclude
=
taurusi[6300-6400],taurusi[5400-5500]
--time
=
00:5:00
--mem-per-cpu
=
1900
--partition
=
haswell bash
-c
"ulimit -s unlimited && mpirun -np 192 src/pdata --report_level=no
"
if
[
$?
-ne
0
]
;
then
curl
-X
POST
--data
"payload={
\"
icon_emoji
\"
:
\"
:jenkins:
\"
,
\"
username
\"
:
\"
jenkins
\"
,
\"
attachments
\"
:[{
\"
title
\"
:
\"
Error:
\"
,
\"
color
\"
:
\"
#FF0000
\"
,
\"
text
\"
:
\"
$2
failed to complete the openfpm_pdata test
\"
}] }"
https://hooks.slack.com/services/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
exit
1
;
fi
salloc
--nodes
=
1
6
--ntasks-per-node
=
16
--time
=
00:10:00
--mem-per-cpu
=
1900
--partition
=
haswell bash
-c
"ulimit -s unlimited && mpirun -np 256 src/pdata
"
salloc
--nodes
=
1
0
--ntasks-per-node
=
24
--exclude
=
taurusi[6300-6400],taurusi[5400-5500]
--time
=
00:5:00
--mem-per-cpu
=
1900
--partition
=
haswell bash
-c
"ulimit -s unlimited && mpirun -np 240 src/pdata --report_level=no
"
if
[
$?
-ne
0
]
;
then
curl
-X
POST
--data
"payload={
\"
icon_emoji
\"
:
\"
:jenkins:
\"
,
\"
username
\"
:
\"
jenkins
\"
,
\"
attachments
\"
:[{
\"
title
\"
:
\"
Error:
\"
,
\"
color
\"
:
\"
#FF0000
\"
,
\"
text
\"
:
\"
$2
failed to complete the openfpm_pdata test
\"
}] }"
https://hooks.slack.com/services/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
exit
1
;
...
...
@@ -258,7 +258,6 @@ then
else
echo
"Compiling general"
source
~/.bashrc
sh ./autogen.sh
./install
-s
mpirun
-np
2 ./src/pdata
...
...
configure.ac
View file @
544e4014
...
...
@@ -7,7 +7,7 @@ AC_PREREQ(2.59)
AC_INIT(FULL-PACKAGE-NAME, VERSION, BUG-REPORT-ADDRESS)
AC_CANONICAL_SYSTEM
AC_CONFIG_SRCDIR([src/main.cpp])
AC_CONFIG_SUBDIRS([openfpm_data openfpm_devices openfpm_vcluster openfpm_io])
AC_CONFIG_SUBDIRS([openfpm_data openfpm_devices openfpm_vcluster openfpm_io
openfpm_numerics
])
#### Adding --with-pdata option and openfpm_pdata to prefix folder
...
...
@@ -25,20 +25,42 @@ ac_configure_args="$ac_configure_args --with-pdata=../../src"
AM_INIT_AUTOMAKE
AC_CONFIG_HEADER([src/config/config.h])
m4_ifdef([ACX_PTHREAD],,[m4_include([m4/acx_pthread.m4])])
m4_ifdef([AX_BOOST],,[m4_include([m4/ax_boost.m4])])
m4_ifdef([ACX_MPI],,[m4_include([m4/acx_mpi.m4])])
m4_ifdef([AX_OPENMP],,[m4_include([m4/ax_openmp.m4])])
m4_ifdef([AX_CUDA],,[m4_include([m4/ax_cuda.m4])])
m4_ifdef([IMMDX_LIB_METIS],,[m4_include([m4/immdx_lib_metis.m4])])
m4_ifdef([IMMDX_LIB_PARMETIS],,[m4_include([m4/immdx_lib_parmetis.m4])])
m4_ifdef([AX_BOOST_BASE],,[m4_include([m4/ax_boost_base.m4])])
m4_ifdef([AX_BOOST_IOSTREAMS],,[m4_include([m4/ax_boost_iostreams.m4])])
m4_ifdef([AX_BOOST_PROGRAM_OPTIONS],,[m4_include([m4/ax_boost_program_options.m4])])
m4_ifdef([AX_BOOST_UNIT_TEST_FRAMEWORK],,[m4_include([m4/ax_boost_unit_test_framework.m4])])
m4_ifdef([AX_BLAS],,[m4_include([m4/ax_blas.m4])])
m4_ifdef([AX_LAPACK],,[m4_include([m4/ax_lapack.m4])])
m4_ifdef([AX_SUITESPARSE],,[m4_include([m4/ax_suitesparse.m4])])
m4_ifdef([AX_EIGEN],,[m4_include([m4/ax_eigen.m4])])
case $host_os in
*cygwin*)
# Do something specific for cygwin
CXXFLAGS+=" --std=gnu++11 "
;;
*)
#Default Case
CXXFLAGS+=" --std=c++11 "
;;
esac
CXXFLAGS+=" --std=c++11 "
NVCCFLAGS=" "
INCLUDES_PATH=" "
# Create a file with the install base folder
echo "$base" > install_dir
# Needed for build library
AC_PROG_RANLIB
AM_PROG_AR
# Checks for programs.
AC_PROG_CXX
...
...
@@ -82,29 +104,32 @@ else
NVCCFLAGS+="$NVCCFLAGS -O3 "
fi
## Check for memcheck
#########
## Check for Metis
IMMDX_LIB_METIS([],[echo "Cannot detect metis, use the --with-metis option if it is not installed in the default location"
exit 201])
########
AC_MSG_CHECKING(whether to build with memcheck capabilities)
AC_ARG_ENABLE(memcheck,
## Enable scan coverty
AC_MSG_CHECKING(whether to build for scan coverty compilation)
AC_ARG_ENABLE(scan-coverty,
AC_HELP_STRING(
[--enable-
memcheck
],
[enable
memory check
(def=no)]
[--enable-
scan-coverty
],
[enable
scan-coverty compilation
(def=no)]
),
memcheck
="$enableval"
scancoverty
="$enableval"
)
AC_MSG_RESULT($
memcheck
)
AC_MSG_RESULT($
scancoverty
)
if test x"$
memcheck
" = x"yes"; then
AC_DEFINE([
MEMLEAK_CHECK],[],[Memory check, corruption and leak
])
if test x"$
scancoverty
" = x"yes"; then
AC_DEFINE([
COVERTY_SCAN],[],[Compile for coverty scan
])
fi
#########
## Check for Metis
IMMDX_LIB_METIS([],[echo "Cannot detect metis, use the --with-metis option if it is not installed in the default location"
exit 201])
## Check for parMetis
...
...
@@ -113,7 +138,7 @@ IMMDX_LIB_PARMETIS([],[echo "Cannot detect parmetis, use the --with-parmetis opt
####### include OpenFPM_devices include path
INCLUDES_PATH+="-I. -I
src/
config/ -I../openfpm_io/src -I../openfpm_data/src -I../openfpm_devices/src -I../openfpm_vcluster/src/"
INCLUDES_PATH+="-I. -Iconfig/ -I../openfpm_io/src -I../openfpm_data/src -I../openfpm_devices/src -I../openfpm_vcluster/src/"
###### Check for se-class1
...
...
@@ -190,8 +215,60 @@ fi
##### CHECK FOR BOOST ##############
AX_BOOST([1.52],[],[echo "boost not found"
AX_BOOST
_BASE
([1.52],[],[echo "boost not found"
exit 202])
AX_BOOST_UNIT_TEST_FRAMEWORK
AX_BOOST_PROGRAM_OPTIONS
AX_BOOST_IOSTREAMS
if test x"$ax_cv_boost_unit_test_framework" = x"no"; then
echo "Notify boost not usable"
exit 202
fi
if test x"$ax_cv_boost_iostreams" = x"no"; then
echo "Notify boost not usable"
exit 202
fi
if test x"$ax_cv_boost_programs_options" = x"no"; then
echo "Notify boost not usable"
exit 202
fi
### Unfortunately a lot of linux distros install a pretty old MPI in the system wide folder,
### override such MPI with the installed one is extremely difficult and tricky, because we want
### to include "some" system library but exclude mpi. One possibility is to give specifically
### the wanted libmpi.so directly to the linker. But this is not possible because this lib is
### given by mpic++ in the form -L/path/to/mpi -lmpi, the other is completely eliminate every
### -L with a system default library
###
# eliminate any /usr/lib and and /usr/include from $BOOST_LIB and $BOOST_INCLUDE
BOOST_LDFLAGS=$(echo "$BOOST_LDFLAGS" | sed -e 's/ -L\/usr\/lib64[ \b]//g' | sed -e 's/ -L\/usr\/lib[ \b]//g')
BOOST_CPPFLAGS=$(echo "$BOOST_CPPFLAGS" | sed -e 's/-I\/usr\/include[ \b]//g')
AC_SUBST(BOOST_LDFLAGS)
AC_SUBST(BOOST_CPPFLAGS)
###### Checking for OpenBLAS
AX_BLAS([],[echo "blas not found"
exit 204])
AX_LAPACK([],[echo "lapack not found"
exit 204])
###### Checking for SUITESPARSE
AX_SUITESPARSE([],[echo "suitesparse not found"
exit 205])
###### Checking for EIGEN
AX_EIGEN([],[echo "eigen not found"
exit 206])
####### Checking for GPU support
...
...
example/Grid/0_simple/main.cpp
View file @
544e4014
#include "Grid/grid_dist_id.hpp"
#include "data_type/
scalar
.hpp"
#include "data_type/
aggregate
.hpp"
#include "Decomposition/CartDecomposition.hpp"
/*
...
...
@@ -26,9 +26,9 @@ int main(int argc, char* argv[])
//
// ### WIKI 3 ###
//
// Create
several object needed later, in particular
// Create
// * A 3D box that define the domain
// * an array of 3 unsigned integer that define the size of the grid on each dimension
// * an array of 3 unsigned integer that
will
define the size of the grid on each dimension
// * A Ghost object that will define the extension of the ghost part for each sub-domain in physical units
Box
<
3
,
float
>
domain
({
0.0
,
0.0
,
0.0
},{
1.0
,
1.0
,
1.0
});
...
...
@@ -43,8 +43,9 @@ int main(int argc, char* argv[])
//
// ### WIKI 4 ###
//
// Create a distributed grid in 3D (1° template parameter) defined in R^3 with float precision (2° template parameter)
// using a CartesianDecomposition strategy (3° parameter) (the parameter 1° and 2° inside CartDecomposition must match 1° and 2°
// Create a distributed grid in 3D (1° template parameter) space in with float precision (2° template parameter)
// each grid point contain a vector of dimension 3 (float[3]),
// using a CartesianDecomposition strategy (4° parameter) (the parameter 1° and 2° inside CartDecomposition must match 1° and 2°
// of grid_dist_id)
//
// Constructor parameters:
...
...
@@ -53,11 +54,11 @@ int main(int argc, char* argv[])
// * domain: where the grid is defined
// * g: ghost extension
//
grid_dist_id
<
3
,
float
,
scalar
<
float
[
3
]
>
,
CartDecomposition
<
3
,
float
>>
g_dist
(
sz
,
domain
,
g
);
grid_dist_id
<
3
,
float
,
aggregate
<
float
[
3
]
>
,
CartDecomposition
<
3
,
float
>>
g_dist
(
sz
,
domain
,
g
);
// ### WIKI 5 ###
//
// Get an iterator that go through
t the point of the domain
(No ghost)
// Get an iterator that go through
the points of the grid
(No ghost)
//
auto
dom
=
g_dist
.
getDomainIterator
();
...
...
@@ -71,8 +72,8 @@ int main(int argc, char* argv[])
//
// ### WIKI 6 ###
//
// Get the local grid key, the local grid key store internaly the sub-domain id (each sub-domain contain a grid)
// and the local grid point id identified by 2 integers in 2D 3 integer in 3D and so on. These two di
nstinc element
are
// Get the local grid key, the local grid key store internal
l
y the sub-domain id (each sub-domain contain a grid)
// and the local grid point id identified by 2 integers in 2D 3 integer in 3D and so on. These two di
stinct elements
are
// available with key.getSub() and key.getKey()
//
auto
key
=
dom
.
get
();
...
...
@@ -120,7 +121,7 @@ int main(int argc, char* argv[])
//
// count contain the number of points the local processor contain, if we are interested to count the total number across the processor
// we can use the function add, to sum across processors. First we have to get an instance of Vcluster, queue an operation of add with
// the variable count and final
y execute. All the operation are asynchronous, execute work like a barrier and ensure that all the
// the variable count and final
ly execute. All the operation are asynchronous, execute work like a barrier and ensure that all the
// queued operations are executed
//
Vcluster
&
vcl
=
g_dist
.
getVC
();
...
...
@@ -142,9 +143,9 @@ int main(int argc, char* argv[])
//
// ### WIKI 13 ###
//
// For debugging p
orpouse and demo
stration we output the decomposition
// For debugging p
urpose and demon
stration we output the decomposition
//
g_dist
.
getDecomposition
().
write
(
"
dec/out
"
);
g_dist
.
getDecomposition
().
write
(
"
out_dec
"
);
//
// ### WIKI 14 ###
...
...
example/Grid/1_stencil/main.cpp
View file @
544e4014
#include "Grid/grid_dist_id.hpp"
#include "data_type/
scalar
.hpp"
#include "data_type/
aggregate
.hpp"
#include "Decomposition/CartDecomposition.hpp"
/*
...
...
@@ -7,9 +7,8 @@
*
* ## Simple example
*
* This example show how to move grid_key in order to create a laplacian stencil,
* be carefull, the function move are convenient, we suggest to not use in case speed
* of a speed critical part of the code
* This example show how to move grid_key in order to create a Laplacian stencil,
* be careful, the function move are convenient, but not the fastest implementation
*
* ### WIKI END ###
*
...
...
@@ -19,13 +18,18 @@
*
* ### WIKI 2 ###
*
* Define some convenient constant
* Define some convenient constant
s and types
*
*/
constexpr
size_t
x
=
0
;
constexpr
size_t
y
=
1
;
constexpr
size_t
z
=
2
;
constexpr
size_t
A
=
0
;
constexpr
size_t
B
=
0
;
typedef
aggregate
<
float
[
3
],
float
[
3
]
>
grid_point
;
int
main
(
int
argc
,
char
*
argv
[])
{
//
...
...
@@ -55,8 +59,9 @@ int main(int argc, char* argv[])
//
// ### WIKI 4 ###
//
// Create a distributed grid in 3D (1° template parameter) defined in R^3 with float precision (2° template parameter)
// using a CartesianDecomposition strategy (3° parameter) (the parameter 1° and 2° inside CartDecomposition must match 1° and 2°
// Create a distributed grid in 3D (1° template parameter) space in with float precision (2° template parameter)
// each grid point contain a vector of dimension 3 (float[3]),
// using a CartesianDecomposition strategy (4° parameter) (the parameter 1° and 2° inside CartDecomposition must match 1° and 2°
// of grid_dist_id)
//
// Constructor parameters:
...
...
@@ -65,7 +70,7 @@ int main(int argc, char* argv[])
// * domain: where the grid is defined
// * g: ghost extension
//
grid_dist_id
<
3
,
float
,
scalar
<
float
[
3
]
>
,
CartDecomposition
<
3
,
float
>>
g_dist
(
sz
,
domain
,
g
);
grid_dist_id
<
3
,
float
,
grid_point
,
CartDecomposition
<
3
,
float
>>
g_dist
(
sz
,
domain
,
g
);
// ### WIKI 5 ###
//
...
...
@@ -80,8 +85,8 @@ int main(int argc, char* argv[])
//
// ### WIKI 6 ###
//
// Get the local grid key, the local grid key store internaly the sub-domain id (each sub-domain contain a grid)
// and the local grid point id identified by 2 integers in 2D 3 integer in 3D and so on. These two di
nstinc element
are
// Get the local grid key, the local grid key store internal
l
y the sub-domain id (each sub-domain contain a grid)
// and the local grid point id identified by 2 integers in 2D 3 integer in 3D and so on. These two di
stinct elements
are
// available with key.getSub() and key.getKey()
//
auto
key
=
dom
.
get
();
...
...
@@ -126,20 +131,20 @@ int main(int argc, char* argv[])
// Get again another iterator, iterate across all the domain points, calculating a Laplace stencil
//
//
dom
=
g_dist
.
getDomainIterator
();
auto
dom2
=
g_dist
.
getDomainIterator
();
while
(
dom
.
isNext
())
while
(
dom
2
.
isNext
())
{
auto
key
=
dom
.
get
();
auto
key
=
dom
2
.
get
();
// Laplace stencil
g_dist
.
template
get
<
0
>(
key
)[
1
]
=
g_dist
.
template
get
<
0
>(
key
.
move
(
x
,
1
))[
0
]
+
g_dist
.
template
get
<
0
>(
key
.
move
(
x
,
-
1
))[
0
]
+
g_dist
.
template
get
<
0
>(
key
.
move
(
y
,
1
))[
0
]
+
g_dist
.
template
get
<
0
>(
key
.
move
(
y
,
-
1
))[
0
]
+
g_dist
.
template
get
<
0
>(
key
.
move
(
z
,
1
))[
0
]
+
g_dist
.
template
get
<
0
>(
key
.
move
(
z
,
-
1
))[
0
]
-
6
*
g_dist
.
template
get
<
0
>(
key
)[
0
];
g_dist
.
template
get
<
B
>(
key
)[
1
]
=
g_dist
.
template
get
<
A
>(
key
.
move
(
x
,
1
))[
0
]
+
g_dist
.
template
get
<
A
>(
key
.
move
(
x
,
-
1
))[
0
]
+
g_dist
.
template
get
<
A
>(
key
.
move
(
y
,
1
))[
0
]
+
g_dist
.
template
get
<
A
>(
key
.
move
(
y
,
-
1
))[
0
]
+
g_dist
.
template
get
<
A
>(
key
.
move
(
z
,
1
))[
0
]
+
g_dist
.
template
get
<
A
>(
key
.
move
(
z
,
-
1
))[
0
]
-
6
*
g_dist
.
template
get
<
A
>(
key
)[
0
];
++
dom
;
++
dom
2
;
}
//
...
...
example/Numerics/Makefile
0 → 100644
View file @
544e4014
SUBDIRS
:=
$(
wildcard
*
/.
)
all clean
:
for
dir
in
$(SUBDIRS)
;
do
\
$(MAKE)
-C
$$
dir
$@
;
\
done
clean
:
$(SUBDIRS)
.PHONY
:
all clean $(SUBDIRS)
example/Numerics/PSE/0_Derivative_approx_1D/Makefile
0 → 100644
View file @
544e4014
include
../../../example.mk
CC
=
mpic++
LDIR
=
OBJ
=
main.o
%.o
:
%.cpp
$(CC)
-O3
-c
--std
=
c++11
-o
$@
$<
$(INCLUDE_PATH)
pse_1d
:
$(OBJ)
$(CC)
-o
$@
$^
$(CFLAGS)
$(LIBS_PATH)
$(LIBS)
all
:
pse_1d
.PHONY
:
clean all
clean
:
rm
-f
*
.o
*
~ core pse_1d
example/Numerics/PSE/0_Derivative_approx_1D/main.cpp
0 → 100644
View file @
544e4014
/*
* ### WIKI 1 ###
*
* ## Simple example
*
* In this example we show 1D PSE derivative function approximation
*
* ### WIKI END ###
*
*/
#include "Vector/vector_dist.hpp"
#include "Decomposition/CartDecomposition.hpp"
#include "PSE/Kernels.hpp"
#include "data_type/aggregate.hpp"
#include <cmath>
/*
* ### WIKI 2 ###
*
* Here we define the function x*e^(-x*x) and its
* second derivative in analytic form
*