Commit 17ab1961 authored by incardon's avatar incardon

Map fully coded

parent 0253fa3b
......@@ -7,7 +7,7 @@ AC_INIT(FULL-PACKAGE-NAME, VERSION, BUG-REPORT-ADDRESS)
AC_CANONICAL_SYSTEM
AC_CONFIG_SRCDIR([src/main.cpp])
AM_INIT_AUTOMAKE
AC_CONFIG_HEADER([src/config.h])
AC_CONFIG_HEADER([src/config/config.h])
m4_ifdef([MYSQL_FOUND],,[m4_include([m4/ax_lib_mysql.m4])])
m4_ifdef([AX_CHECK_COMPILER_FLAGS],,[m4_include([m4/ax_check_compiler_flags.m4])])
m4_ifdef([ACX_PTHREAD],,[m4_include([m4/acx_pthread.m4])])
......@@ -83,7 +83,7 @@ fi
####### include OpenFPM_devices include path
INCLUDES_PATH+="-I. -I../../metis_install/include -I../../OpenFPM_IO/src -I../../OpenFPM_data/src -I../../OpenFPM_devices/src -I../../OpenFPM_vcluster/src/"
INCLUDES_PATH+="-I. -Isrc/config/ -I../../metis_install/include -I../../OpenFPM_IO/src -I../../OpenFPM_data/src -I../../OpenFPM_devices/src -I../../OpenFPM_vcluster/src/"
####### Checking for GPU support
......
pdata-HeapMemory.o: ../../OpenFPM_devices/src/memory/HeapMemory.cpp \
/usr/include/stdc-predef.h \
../../OpenFPM_devices/src/memory/HeapMemory.hpp config.h \
../../OpenFPM_data/src/memory.hpp ../../OpenFPM_data/src/config.h \
../../OpenFPM_data/src/memory.hpp \
/usr/lib/gcc/x86_64-redhat-linux/4.8.3/include/stddef.h \
/usr/include/c++/4.8.3/cstddef \
/usr/include/c++/4.8.3/x86_64-redhat-linux/bits/c++config.h \
......@@ -95,7 +95,15 @@ pdata-HeapMemory.o: ../../OpenFPM_devices/src/memory/HeapMemory.cpp \
/usr/include/c++/4.8.3/bits/basic_ios.tcc \
/usr/include/c++/4.8.3/bits/ostream.tcc /usr/include/c++/4.8.3/istream \
/usr/include/c++/4.8.3/bits/istream.tcc /usr/include/c++/4.8.3/cstring \
/usr/include/string.h
/usr/include/string.h ../../OpenFPM_data/src/Memleak_check.hpp \
/usr/include/c++/4.8.3/map /usr/include/c++/4.8.3/bits/stl_tree.h \
/usr/include/c++/4.8.3/bits/alloc_traits.h \
/usr/include/c++/4.8.3/bits/ptr_traits.h \
/usr/include/c++/4.8.3/bits/stl_map.h /usr/include/c++/4.8.3/tuple \
/usr/include/c++/4.8.3/utility /usr/include/c++/4.8.3/bits/stl_relops.h \
/usr/include/c++/4.8.3/array /usr/include/c++/4.8.3/stdexcept \
/usr/include/c++/4.8.3/bits/uses_allocator.h \
/usr/include/c++/4.8.3/bits/stl_multimap.h
/usr/include/stdc-predef.h:
......@@ -105,8 +113,6 @@ config.h:
../../OpenFPM_data/src/memory.hpp:
../../OpenFPM_data/src/config.h:
/usr/lib/gcc/x86_64-redhat-linux/4.8.3/include/stddef.h:
/usr/include/c++/4.8.3/cstddef:
......@@ -362,3 +368,29 @@ config.h:
/usr/include/c++/4.8.3/cstring:
/usr/include/string.h:
../../OpenFPM_data/src/Memleak_check.hpp:
/usr/include/c++/4.8.3/map:
/usr/include/c++/4.8.3/bits/stl_tree.h:
/usr/include/c++/4.8.3/bits/alloc_traits.h:
/usr/include/c++/4.8.3/bits/ptr_traits.h:
/usr/include/c++/4.8.3/bits/stl_map.h:
/usr/include/c++/4.8.3/tuple:
/usr/include/c++/4.8.3/utility:
/usr/include/c++/4.8.3/bits/stl_relops.h:
/usr/include/c++/4.8.3/array:
/usr/include/c++/4.8.3/stdexcept:
/usr/include/c++/4.8.3/bits/uses_allocator.h:
/usr/include/c++/4.8.3/bits/stl_multimap.h:
pdata-Memleak_check.o: ../../OpenFPM_data/src/Memleak_check.cpp \
/usr/include/stdc-predef.h ../../OpenFPM_data/src/Memleak_check.hpp \
/usr/include/c++/4.8.3/iostream \
/usr/include/stdc-predef.h config.h \
../../OpenFPM_data/src/Memleak_check.hpp /usr/include/c++/4.8.3/iostream \
/usr/include/c++/4.8.3/x86_64-redhat-linux/bits/c++config.h \
/usr/include/bits/wordsize.h \
/usr/include/c++/4.8.3/x86_64-redhat-linux/bits/os_defines.h \
......@@ -103,6 +103,8 @@ pdata-Memleak_check.o: ../../OpenFPM_data/src/Memleak_check.cpp \
/usr/include/stdc-predef.h:
config.h:
../../OpenFPM_data/src/Memleak_check.hpp:
/usr/include/c++/4.8.3/iostream:
......
......@@ -939,8 +939,8 @@ pdata-VCluster.o: ../../OpenFPM_vcluster/src/VCluster.cpp \
/usr/include/boost/detail/call_traits.hpp \
../../OpenFPM_data/src/ct_array.hpp \
../../OpenFPM_data/src/memory_array.hpp \
../../OpenFPM_data/src/memory.hpp ../../OpenFPM_data/src/config.h \
../../OpenFPM_data/src/memory.hpp ../../OpenFPM_data/src/meta_copy.hpp \
../../OpenFPM_data/src/memory.hpp ../../OpenFPM_data/src/memory.hpp \
../../OpenFPM_data/src/meta_copy.hpp \
../../OpenFPM_data/src/Memleak_check.hpp \
../../OpenFPM_data/src/for_each_ref.hpp \
../../OpenFPM_data/src/Grid/grid_sm.hpp \
......@@ -3023,8 +3023,6 @@ config.h:
../../OpenFPM_data/src/memory.hpp:
../../OpenFPM_data/src/config.h:
../../OpenFPM_data/src/memory.hpp:
../../OpenFPM_data/src/meta_copy.hpp:
......
......@@ -901,8 +901,8 @@ pdata-main.o: main.cpp /usr/include/stdc-predef.h \
/usr/include/boost/detail/call_traits.hpp \
../../OpenFPM_data/src/ct_array.hpp \
../../OpenFPM_data/src/memory_array.hpp \
../../OpenFPM_data/src/memory.hpp ../../OpenFPM_data/src/config.h \
../../OpenFPM_data/src/memory.hpp ../../OpenFPM_data/src/meta_copy.hpp \
../../OpenFPM_data/src/memory.hpp ../../OpenFPM_data/src/memory.hpp \
../../OpenFPM_data/src/meta_copy.hpp \
../../OpenFPM_data/src/Memleak_check.hpp /usr/include/c++/4.8.3/map \
/usr/include/c++/4.8.3/bits/stl_tree.h \
/usr/include/c++/4.8.3/bits/stl_map.h \
......@@ -1293,6 +1293,7 @@ pdata-main.o: main.cpp /usr/include/stdc-predef.h \
SubdomainGraphNodes.hpp metis_util.hpp \
../../metis_install/include/metis.h /usr/include/inttypes.h \
../../OpenFPM_IO/src/VTKWriter.hpp dec_optimizer.hpp \
../../OpenFPM_data/src/NN/CellList/CellDecomposer.hpp \
../../OpenFPM_data/src/util.hpp Decomposition/ORB_unit_test.hpp \
Decomposition/ORB.hpp ../../OpenFPM_data/src/data_type/scalar.hpp \
Graph/CartesianGraphFactory_unit_test.hpp \
......@@ -1301,7 +1302,11 @@ pdata-main.o: main.cpp /usr/include/stdc-predef.h \
Grid/grid_dist_id_unit_test.hpp Grid/grid_dist_id.hpp \
Vector/vector_dist_unit_test.hpp Vector/vector_dist.hpp \
Vector/vector_dist_iterator.hpp Vector/vector_dist_key.hpp \
Vector/vector_dist_key.hpp Decomposition/CartDecomposition_unit_test.hpp \
Vector/vector_dist_key.hpp \
../../OpenFPM_devices/src/memory/PreAllocHeapMemory.hpp \
../../OpenFPM_devices/src/memory/HeapMemory.hpp \
../../OpenFPM_devices/src/memory/PtrMemory.hpp \
Decomposition/CartDecomposition_unit_test.hpp \
Decomposition/CartDecomposition.hpp
/usr/include/stdc-predef.h:
......@@ -3286,8 +3291,6 @@ config.h:
../../OpenFPM_data/src/memory.hpp:
../../OpenFPM_data/src/config.h:
../../OpenFPM_data/src/memory.hpp:
../../OpenFPM_data/src/meta_copy.hpp:
......@@ -4174,6 +4177,8 @@ metis_util.hpp:
dec_optimizer.hpp:
../../OpenFPM_data/src/NN/CellList/CellDecomposer.hpp:
../../OpenFPM_data/src/util.hpp:
Decomposition/ORB_unit_test.hpp:
......@@ -4208,6 +4213,12 @@ Vector/vector_dist_key.hpp:
Vector/vector_dist_key.hpp:
../../OpenFPM_devices/src/memory/PreAllocHeapMemory.hpp:
../../OpenFPM_devices/src/memory/HeapMemory.hpp:
../../OpenFPM_devices/src/memory/PtrMemory.hpp:
Decomposition/CartDecomposition_unit_test.hpp:
Decomposition/CartDecomposition.hpp:
......@@ -19,6 +19,7 @@
#include "dec_optimizer.hpp"
#include "Space/Shape/Box.hpp"
#include "Space/Shape/Point.hpp"
#include "NN/CellList/CellDecomposer.hpp"
/**
* \brief This class decompose a space into subspaces
......@@ -43,6 +44,7 @@ template<unsigned int dim, typename T, template<typename> class device_l=openfpm
class CartDecomposition
{
public:
//! Type of the domain we are going to decompose
typedef T domain_type;
......@@ -51,7 +53,7 @@ public:
private:
//! This is the key type toaccess data_s, for example in the case of vector
//! This is the key type to access data_s, for example in the case of vector
//! acc_key is size_t
typedef typename data_s<SpaceBox<dim,T>,device_l<SpaceBox<dim,T>>,Memory,openfpm::vector_grow_policy_default,openfpm::vect_isel<SpaceBox<dim,T>>::value >::access_key acc_key;
......@@ -69,11 +71,12 @@ private:
//! exist for efficient global communication
openfpm::vector<size_t> fine_s;
//! number of total sub-domain
size_t N_tot;
//! Structure that store the cartesian grid information
grid_sm<dim,void> gr;
//! number of sub-domain on each dimension
size_t div[dim];
//! Structure that decompose your structure into cell without creating them
//! useful to convert positions to CellId or sub-domain id in this case
CellDecomposer_sm<dim,T> cd;
//! rectangular domain to decompose
Domain<dim,T> domain;
......@@ -94,8 +97,6 @@ private:
// Calculate the total number of box and and the spacing
// on each direction
N_tot = 1;
// Get the box containing the domain
SpaceBox<dim,T> bs = domain.getBox();
......@@ -103,8 +104,7 @@ private:
{
// Calculate the spacing
spacing[i] = (bs.getHigh(i) - bs.getLow(i)) / div[i];
N_tot *= div[i];
spacing[i] = (bs.getHigh(i) - bs.getLow(i)) / gr.size(i);
}
// Here we use METIS
......@@ -114,7 +114,7 @@ private:
// Processor graph
Graph_CSR<nm_part_v,nm_part_e> gp = g_factory_part.template construct<NO_EDGE,T,dim-1>(div,domain);
Graph_CSR<nm_part_v,nm_part_e> gp = g_factory_part.template construct<NO_EDGE,T,dim-1>(gr.getSize(),domain);
// Get the number of processing units
size_t Np = v_cl.getProcessingUnits();
......@@ -131,12 +131,12 @@ private:
// fill the structure that store the processor id for each sub-domain
fine_s.resize(N_tot);
fine_s.resize(gr.size());
// Optimize the decomposition creating bigger spaces
// And reducing Ghost over-stress
dec_optimizer<dim,Graph_CSR<nm_part_v,nm_part_e>> d_o(gp,div);
dec_optimizer<dim,Graph_CSR<nm_part_v,nm_part_e>> d_o(gp,gr.getSize());
// set of Boxes produced by the decomposition optimizer
openfpm::vector<::Box<dim,size_t>> loc_box;
......@@ -155,6 +155,19 @@ private:
// add the sub-domain
sub_domains.add(sub_d);
}
// fill fine_s structure
auto it = gp.getVertexIterator();
while (it.isNext())
{
size_t key = it.get();
// fill with the fine decomposition
fine_s.get(key) = gp.template vertex_p<nm_part_v::id>(key);
++it;
}
}
/*! \brief Create the subspaces that decompose your domain
......@@ -210,7 +223,7 @@ public:
*
*/
CartDecomposition(CartDecomposition<dim,T,device_l,Memory,Domain,data_s> && cd)
:sub_domain(cd.sub_domain),N_tot(cd.N_tot),domain(cd.domain),v_cl(cd.v_cl)
:sub_domain(cd.sub_domain),gr(cd.gr),cd(cd.cd),domain(cd.domain),v_cl(cd.v_cl)
{
//! Subspace selected
//! access_key in case of grid is just the set of the index to access the grid
......@@ -221,8 +234,6 @@ public:
for (int i = 0 ; i < dim ; i++)
{
this->div[i] = div[dim];
//! Box Spacing
this->spacing[i] = spacing[i];
}
......@@ -234,7 +245,7 @@ public:
*
*/
CartDecomposition(Vcluster & v_cl)
:id_sub(0),N_tot(0),v_cl(v_cl)
:id_sub(0),v_cl(v_cl)
{}
/*! \brief Cartesian decomposition constructor, it divide the space in boxes
......@@ -245,7 +256,7 @@ public:
*
*/
CartDecomposition(std::vector<size_t> dec, Domain<dim,T> domain, Vcluster & v_cl)
:id_sub(0),div(dec),domain(domain),v_cl(v_cl)
:id_sub(0),gr(dec),cd(domain,dec),domain(domain),v_cl(v_cl)
{
// Create the decomposition
......@@ -264,14 +275,7 @@ public:
template<typename Mem> size_t inline processorID(encapc<1, Point<dim,T>, Mem> p)
{
size_t pid = 0;
for (size_t i = 0 ; i < dim ; i++)
{
pid += p.template get<Point<dim,T>::x>()[i];
}
return pid;
return fine_s.get(cd.getCell(p));
}
/*! \brief processorID return in which processor the particle should go
......@@ -282,14 +286,7 @@ public:
size_t inline processorID(T (&p)[dim])
{
size_t pid = 0;
for (size_t i = 0 ; i < dim ; i++)
{
pid += p[i];
}
return pid;
return fine_s.get(cd.getCell(p));
}
/*! \brief Set the parameter of the decomposition
......@@ -316,14 +313,13 @@ public:
* \param domain_ domain to decompose
*
*/
void setParameters(size_t div_[dim], Domain<dim,T> domain_)
void setParameters(const size_t (& div_)[dim], Domain<dim,T> domain_)
{
// Set the decomposition parameters
for (int i = 0 ; i < dim ; i++)
div[i] = div_[i];
gr.setDimensions(div_);
domain = domain_;
cd.setDimensions(domain,div_);
//! Create the decomposition
......@@ -429,7 +425,7 @@ public:
{
#ifdef DEBUG
// Check if this subspace exist
if (id >= N_tot)
if (id >= gr.size())
{
std::cerr << "Error CartDecomposition: id > N_tot";
}
......@@ -453,7 +449,7 @@ public:
size_t getNHyperCube()
{
return N_tot;
return gr.size();
}
/*! \brief produce an hyper-cube approximation of the space decomposition
......
......@@ -49,7 +49,7 @@ BOOST_AUTO_TEST_CASE( ORB_test_use)
// Orthogonal Recursive Bisection
Box<3,float> dom({0.0,0.0,0.0},{1.0,1.0,1.0});
ORB<3,float> orb(dom,16,vp);
// ORB<3,float> orb(dom,16,vp);
//
}
......
......@@ -107,7 +107,7 @@ BOOST_AUTO_TEST_CASE( grid_dist_id_iterator_test_use)
BOOST_AUTO_TEST_CASE( grid_dist_id_poisson_test_use)
{
// grid size
size_t sz[2] = {1024,1024};
/* size_t sz[2] = {1024,1024};
// Distributed grid with id decomposition
......@@ -115,7 +115,7 @@ BOOST_AUTO_TEST_CASE( grid_dist_id_poisson_test_use)
// Create the grid on memory
g_dist.Create();
g_dist.Create();*/
/* auto g_it = g_dist.getIteratorBulk();
......
......@@ -82,7 +82,7 @@ target_triplet = x86_64-unknown-linux-gnu
bin_PROGRAMS = pdata$(EXEEXT)
subdir = src
DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/Makefile.am \
$(srcdir)/config.h.in $(top_srcdir)/depcomp
$(top_srcdir)/depcomp
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
am__aclocal_m4_deps = $(top_srcdir)/m4/ax_lib_mysql.m4 \
$(top_srcdir)/m4/ax_check_compiler_flags.m4 \
......@@ -97,13 +97,14 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/ax_lib_mysql.m4 \
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
$(ACLOCAL_M4)
mkinstalldirs = $(install_sh) -d
CONFIG_HEADER = config.h
CONFIG_HEADER = $(top_builddir)/src/config/config.h
CONFIG_CLEAN_FILES =
CONFIG_CLEAN_VPATH_FILES =
am__installdirs = "$(DESTDIR)$(bindir)"
PROGRAMS = $(bin_PROGRAMS)
am_pdata_OBJECTS = pdata-main.$(OBJEXT) pdata-HeapMemory.$(OBJEXT) \
pdata-VCluster.$(OBJEXT) pdata-Memleak_check.$(OBJEXT)
pdata-PtrMemory.$(OBJEXT) pdata-VCluster.$(OBJEXT) \
pdata-Memleak_check.$(OBJEXT)
pdata_OBJECTS = $(am_pdata_OBJECTS)
am__DEPENDENCIES_1 =
am__DEPENDENCIES_2 = $(am__DEPENDENCIES_1)
......@@ -122,7 +123,7 @@ AM_V_at = $(am__v_at_$(V))
am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
am__v_at_0 = @
am__v_at_1 =
DEFAULT_INCLUDES = -I.
DEFAULT_INCLUDES = -I. -I$(top_builddir)/src/config
depcomp = $(SHELL) $(top_srcdir)/depcomp
am__depfiles_maybe = depfiles
am__mv = mv -f
......@@ -150,8 +151,7 @@ am__can_run_installinfo = \
n|no|NO) false;; \
*) (install-info --version) >/dev/null 2>&1;; \
esac
am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) \
$(LISP)config.h.in
am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
# Read a list of newline-separated strings from the standard input,
# and print each of them once, without duplicates. Input order is
# *not* preserved.
......@@ -194,7 +194,7 @@ ECHO_C =
ECHO_N = -n
ECHO_T =
EXEEXT =
INCLUDES_PATH = -I. -I../../metis_install/include -I../../OpenFPM_IO/src -I../../OpenFPM_data/src -I../../OpenFPM_devices/src -I../../OpenFPM_vcluster/src/
INCLUDES_PATH = -I. -Isrc/config/ -I../../metis_install/include -I../../OpenFPM_IO/src -I../../OpenFPM_data/src -I../../OpenFPM_devices/src -I../../OpenFPM_vcluster/src/
INSTALL = /usr/bin/install -c
INSTALL_DATA = ${INSTALL} -m 644
INSTALL_PROGRAM = ${INSTALL}
......@@ -279,12 +279,11 @@ top_build_prefix = ../
top_builddir = ..
top_srcdir = ..
LINKLIBS = $(PTHREAD_LIBS) $(OPT_LIBS) $(BOOST_LDFLAGS) $(BOOST_PROGRAM_OPTIONS_LIB) $(CUDA_LIBS) $(BOOST_THREAD_LIB)
pdata_SOURCES = main.cpp ../../OpenFPM_devices/src/memory/HeapMemory.cpp ../../OpenFPM_vcluster/src/VCluster.cpp ../../OpenFPM_data/src/Memleak_check.cpp
pdata_SOURCES = main.cpp ../../OpenFPM_devices/src/memory/HeapMemory.cpp ../../OpenFPM_devices/src/memory/PtrMemory.cpp ../../OpenFPM_vcluster/src/VCluster.cpp ../../OpenFPM_data/src/Memleak_check.cpp
pdata_CXXFLAGS = $(CUDA_CFLAGS) $(INCLUDES_PATH)
pdata_CFLAGS = $(CUDA_CFLAGS)
pdata_LDADD = $(LINKLIBS) -L/usr/lib64/nvidia-bumblebee/ -L../../metis_install/lib -lmetis
all: config.h
$(MAKE) $(AM_MAKEFLAGS) all-am
all: all-am
.SUFFIXES:
.SUFFIXES: .cpp .cu .o .obj
......@@ -318,21 +317,6 @@ $(top_srcdir)/configure: $(am__configure_deps)
$(ACLOCAL_M4): $(am__aclocal_m4_deps)
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
$(am__aclocal_m4_deps):
config.h: stamp-h1
@if test ! -f $@; then rm -f stamp-h1; else :; fi
@if test ! -f $@; then $(MAKE) $(AM_MAKEFLAGS) stamp-h1; else :; fi
stamp-h1: $(srcdir)/config.h.in $(top_builddir)/config.status
@rm -f stamp-h1
cd $(top_builddir) && $(SHELL) ./config.status src/config.h
$(srcdir)/config.h.in: $(am__configure_deps)
($(am__cd) $(top_srcdir) && $(AUTOHEADER))
rm -f stamp-h1
touch $@
distclean-hdr:
-rm -f config.h stamp-h1
install-binPROGRAMS: $(bin_PROGRAMS)
@$(NORMAL_INSTALL)
@list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \
......@@ -388,6 +372,7 @@ distclean-compile:
include ./$(DEPDIR)/pdata-HeapMemory.Po
include ./$(DEPDIR)/pdata-Memleak_check.Po
include ./$(DEPDIR)/pdata-PtrMemory.Po
include ./$(DEPDIR)/pdata-VCluster.Po
include ./$(DEPDIR)/pdata-main.Po
......@@ -433,6 +418,20 @@ pdata-HeapMemory.obj: ../../OpenFPM_devices/src/memory/HeapMemory.cpp
# DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) \
# $(AM_V_CXX_no)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pdata_CXXFLAGS) $(CXXFLAGS) -c -o pdata-HeapMemory.obj `if test -f '../../OpenFPM_devices/src/memory/HeapMemory.cpp'; then $(CYGPATH_W) '../../OpenFPM_devices/src/memory/HeapMemory.cpp'; else $(CYGPATH_W) '$(srcdir)/../../OpenFPM_devices/src/memory/HeapMemory.cpp'; fi`
pdata-PtrMemory.o: ../../OpenFPM_devices/src/memory/PtrMemory.cpp
$(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pdata_CXXFLAGS) $(CXXFLAGS) -MT pdata-PtrMemory.o -MD -MP -MF $(DEPDIR)/pdata-PtrMemory.Tpo -c -o pdata-PtrMemory.o `test -f '../../OpenFPM_devices/src/memory/PtrMemory.cpp' || echo '$(srcdir)/'`../../OpenFPM_devices/src/memory/PtrMemory.cpp
$(AM_V_at)$(am__mv) $(DEPDIR)/pdata-PtrMemory.Tpo $(DEPDIR)/pdata-PtrMemory.Po
# $(AM_V_CXX)source='../../OpenFPM_devices/src/memory/PtrMemory.cpp' object='pdata-PtrMemory.o' libtool=no \
# DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) \
# $(AM_V_CXX_no)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pdata_CXXFLAGS) $(CXXFLAGS) -c -o pdata-PtrMemory.o `test -f '../../OpenFPM_devices/src/memory/PtrMemory.cpp' || echo '$(srcdir)/'`../../OpenFPM_devices/src/memory/PtrMemory.cpp
pdata-PtrMemory.obj: ../../OpenFPM_devices/src/memory/PtrMemory.cpp
$(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pdata_CXXFLAGS) $(CXXFLAGS) -MT pdata-PtrMemory.obj -MD -MP -MF $(DEPDIR)/pdata-PtrMemory.Tpo -c -o pdata-PtrMemory.obj `if test -f '../../OpenFPM_devices/src/memory/PtrMemory.cpp'; then $(CYGPATH_W) '../../OpenFPM_devices/src/memory/PtrMemory.cpp'; else $(CYGPATH_W) '$(srcdir)/../../OpenFPM_devices/src/memory/PtrMemory.cpp'; fi`
$(AM_V_at)$(am__mv) $(DEPDIR)/pdata-PtrMemory.Tpo $(DEPDIR)/pdata-PtrMemory.Po
# $(AM_V_CXX)source='../../OpenFPM_devices/src/memory/PtrMemory.cpp' object='pdata-PtrMemory.obj' libtool=no \
# DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) \
# $(AM_V_CXX_no)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pdata_CXXFLAGS) $(CXXFLAGS) -c -o pdata-PtrMemory.obj `if test -f '../../OpenFPM_devices/src/memory/PtrMemory.cpp'; then $(CYGPATH_W) '../../OpenFPM_devices/src/memory/PtrMemory.cpp'; else $(CYGPATH_W) '$(srcdir)/../../OpenFPM_devices/src/memory/PtrMemory.cpp'; fi`
pdata-VCluster.o: ../../OpenFPM_vcluster/src/VCluster.cpp
$(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pdata_CXXFLAGS) $(CXXFLAGS) -MT pdata-VCluster.o -MD -MP -MF $(DEPDIR)/pdata-VCluster.Tpo -c -o pdata-VCluster.o `test -f '../../OpenFPM_vcluster/src/VCluster.cpp' || echo '$(srcdir)/'`../../OpenFPM_vcluster/src/VCluster.cpp
$(AM_V_at)$(am__mv) $(DEPDIR)/pdata-VCluster.Tpo $(DEPDIR)/pdata-VCluster.Po
......@@ -545,7 +544,7 @@ distdir: $(DISTFILES)
done
check-am: all-am
check: check-am
all-am: Makefile $(PROGRAMS) config.h
all-am: Makefile $(PROGRAMS)
installdirs:
for dir in "$(DESTDIR)$(bindir)"; do \
test -z "$$dir" || $(MKDIR_P) "$$dir"; \
......@@ -588,7 +587,7 @@ distclean: distclean-am
-rm -rf ./$(DEPDIR)
-rm -f Makefile
distclean-am: clean-am distclean-compile distclean-generic \
distclean-hdr distclean-tags
distclean-tags
dvi: dvi-am
......@@ -649,21 +648,21 @@ ps-am:
uninstall-am: uninstall-binPROGRAMS
.MAKE: all install-am install-strip
.MAKE: install-am install-strip
.PHONY: CTAGS GTAGS TAGS all all-am check check-am clean \
clean-binPROGRAMS clean-generic cscopelist-am ctags ctags-am \
distclean distclean-compile distclean-generic distclean-hdr \
distclean-tags distdir dvi dvi-am html html-am info info-am \
install install-am install-binPROGRAMS install-data \
install-data-am install-dvi install-dvi-am install-exec \
install-exec-am install-html install-html-am install-info \
install-info-am install-man install-pdf install-pdf-am \
install-ps install-ps-am install-strip installcheck \
installcheck-am installdirs maintainer-clean \
maintainer-clean-generic mostlyclean mostlyclean-compile \
mostlyclean-generic pdf pdf-am ps ps-am tags tags-am uninstall \
uninstall-am uninstall-binPROGRAMS
distclean distclean-compile distclean-generic distclean-tags \
distdir dvi dvi-am html html-am info info-am install \
install-am install-binPROGRAMS install-data install-data-am \
install-dvi install-dvi-am install-exec install-exec-am \
install-html install-html-am install-info install-info-am \
install-man install-pdf install-pdf-am install-ps \
install-ps-am install-strip installcheck installcheck-am \
installdirs maintainer-clean maintainer-clean-generic \
mostlyclean mostlyclean-compile mostlyclean-generic pdf pdf-am \
ps ps-am tags tags-am uninstall uninstall-am \
uninstall-binPROGRAMS
.cu.o :
......
......@@ -2,7 +2,7 @@
LINKLIBS = $(PTHREAD_LIBS) $(OPT_LIBS) $(BOOST_LDFLAGS) $(BOOST_PROGRAM_OPTIONS_LIB) $(CUDA_LIBS) $(BOOST_THREAD_LIB)
bin_PROGRAMS = pdata
pdata_SOURCES = main.cpp ../../OpenFPM_devices/src/memory/HeapMemory.cpp ../../OpenFPM_vcluster/src/VCluster.cpp ../../OpenFPM_data/src/Memleak_check.cpp
pdata_SOURCES = main.cpp ../../OpenFPM_devices/src/memory/HeapMemory.cpp ../../OpenFPM_devices/src/memory/PtrMemory.cpp ../../OpenFPM_vcluster/src/VCluster.cpp ../../OpenFPM_data/src/Memleak_check.cpp
pdata_CXXFLAGS = $(CUDA_CFLAGS) $(INCLUDES_PATH)
pdata_CFLAGS = $(CUDA_CFLAGS)
pdata_LDADD = $(LINKLIBS) -L/usr/lib64/nvidia-bumblebee/ -L../../metis_install/lib -lmetis
......
......@@ -82,7 +82,7 @@ target_triplet = @target@
bin_PROGRAMS = pdata$(EXEEXT)
subdir = src
DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/Makefile.am \
$(srcdir)/config.h.in $(top_srcdir)/depcomp
$(top_srcdir)/depcomp
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
am__aclocal_m4_deps = $(top_srcdir)/m4/ax_lib_mysql.m4 \
$(top_srcdir)/m4/ax_check_compiler_flags.m4 \
......@@ -97,13 +97,14 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/ax_lib_mysql.m4 \
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
$(ACLOCAL_M4)
mkinstalldirs = $(install_sh) -d
CONFIG_HEADER = config.h
CONFIG_HEADER = $(top_builddir)/src/config/config.h
CONFIG_CLEAN_FILES =
CONFIG_CLEAN_VPATH_FILES =
am__installdirs = "$(DESTDIR)$(bindir)"
PROGRAMS = $(bin_PROGRAMS)
am_pdata_OBJECTS = pdata-main.$(OBJEXT) pdata-HeapMemory.$(OBJEXT) \
pdata-VCluster.$(OBJEXT) pdata-Memleak_check.$(OBJEXT)
pdata-PtrMemory.$(OBJEXT) pdata-VCluster.$(OBJEXT) \
pdata-Memleak_check.$(OBJEXT)
pdata_OBJECTS = $(am_pdata_OBJECTS)
am__DEPENDENCIES_1 =
am__DEPENDENCIES_2 = $(am__DEPENDENCIES_1)
......@@ -122,7 +123,7 @@ AM_V_at = $(am__v_at_@AM_V@)
am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
am__v_at_0 = @
am__v_at_1 =
DEFAULT_INCLUDES = -I.@am__isrc@
DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir)/src/config
depcomp = $(SHELL) $(top_srcdir)/depcomp
am__depfiles_maybe = depfiles
am__mv = mv -f
......@@ -150,8 +151,7 @@ am__can_run_installinfo = \
n|no|NO) false;; \
*) (install-info --version) >/dev/null 2>&1;; \
esac
am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) \
$(LISP)config.h.in
am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
# Read a list of newline-separated strings from the standard input,
# and print each of them once, without duplicates. Input order is
# *not* preserved.
......@@ -279,12 +279,11 @@ top_build_prefix = @top_build_prefix@
top_builddir = @top_builddir@
top_srcdir = @top_srcdir@
LINKLIBS = $(PTHREAD_LIBS) $(OPT_LIBS) $(BOOST_LDFLAGS) $(BOOST_PROGRAM_OPTIONS_LIB) $(CUDA_LIBS) $(BOOST_THREAD_LIB)
pdata_SOURCES = main.cpp ../../OpenFPM_devices/src/memory/HeapMemory.cpp ../../OpenFPM_vcluster/src/VCluster.cpp ../../OpenFPM_data/src/Memleak_check.cpp
pdata_SOURCES = main.cpp ../../OpenFPM_devices/src/memory/HeapMemory.cpp ../../OpenFPM_devices/src/memory/PtrMemory.cpp ../../OpenFPM_vcluster/src/VCluster.cpp ../../OpenFPM_data/src/Memleak_check.cpp
pdata_CXXFLAGS = $(CUDA_CFLAGS) $(INCLUDES_PATH)
pdata_CFLAGS = $(CUDA_CFLAGS)
pdata_LDADD = $(LINKLIBS) -L/usr/lib64/nvidia-bumblebee/ -L../../metis_install/lib -lmetis
all: config.h
$(MAKE) $(AM_MAKEFLAGS) all-am
all: all-am
.SUFFIXES:
.SUFFIXES: .cpp .cu .o .obj
......@@ -318,21 +317,6 @@ $(top_srcdir)/configure: $(am__configure_deps)
$(ACLOCAL_M4): $(am__aclocal_m4_deps)
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
$(am__aclocal_m4_deps):
config.h: stamp-h1
@if test ! -f $@; then rm -f stamp-h1; else :; fi
@if test ! -f $@; then $(MAKE) $(AM_MAKEFLAGS) stamp-h1; else :; fi
stamp-h1: $(srcdir)/config.h.in $(top_builddir)/config.status
@rm -f stamp-h1
cd $(top_builddir) && $(SHELL) ./config.status src/config.h
$(srcdir)/config.h.in: $(am__configure_deps)
($(am__cd) $(top_srcdir) && $(AUTOHEADER))
rm -f stamp-h1
touch $@
distclean-hdr:
-rm -f config.h stamp-h1
install-binPROGRAMS: $(bin_PROGRAMS)
@$(NORMAL_INSTALL)
@list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \
......@@ -388,6 +372,7 @@ distclean-compile:
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pdata-HeapMemory.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pdata-Memleak_check.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pdata-PtrMemory.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pdata-VCluster.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pdata-main.Po@am__quote@
......@@ -433,6 +418,20 @@ pdata-HeapMemory.obj: ../../OpenFPM_devices/src/memory/HeapMemory.cpp
@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pdata_CXXFLAGS) $(CXXFLAGS) -c -o pdata-HeapMemory.obj `if test -f '../../OpenFPM_devices/src/memory/HeapMemory.cpp'; then $(CYGPATH_W) '../../OpenFPM_devices/src/memory/HeapMemory.cpp'; else $(CYGPATH_W) '$(srcdir)/../../OpenFPM_devices/src/memory/HeapMemory.cpp'; fi`
pdata-PtrMemory.o: ../../OpenFPM_devices/src/memory/PtrMemory.cpp
@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pdata_CXXFLAGS) $(CXXFLAGS) -MT pdata-PtrMemory.o -MD -MP -MF $(DEPDIR)/pdata-PtrMemory.Tpo -c -o pdata-PtrMemory.o `test -f '../../OpenFPM_devices/src/memory/PtrMemory.cpp' || echo '$(srcdir)/'`../../OpenFPM_devices/src/memory/PtrMemory.cpp
@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/pdata-PtrMemory.Tpo $(DEPDIR)/pdata-PtrMemory.Po
@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='../../OpenFPM_devices/src/memory/PtrMemory.cpp' object='pdata-PtrMemory.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pdata_CXXFLAGS) $(CXXFLAGS) -c -o pdata-PtrMemory.o `test -f '../../OpenFPM_devices/src/memory/PtrMemory.cpp' || echo '$(srcdir)/'`../../OpenFPM_devices/src/memory/PtrMemory.cpp
pdata-PtrMemory.obj: ../../OpenFPM_devices/src/memory/PtrMemory.cpp
@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pdata_CXXFLAGS) $(CXXFLAGS) -MT pdata-PtrMemory.obj -MD -MP -MF $(DEPDIR)/pdata-PtrMemory.Tpo -c -o pdata-PtrMemory.obj `if test -f '../../OpenFPM_devices/src/memory/PtrMemory.cpp'; then $(CYGPATH_W) '../../OpenFPM_devices/src/memory/PtrMemory.cpp'; else $(CYGPATH_W) '$(srcdir)/../../OpenFPM_devices/src/memory/PtrMemory.cpp'; fi`
@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/pdata-PtrMemory.Tpo $(DEPDIR)/pdata-PtrMemory.Po
@AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='../../OpenFPM_devices/src/memory/PtrMemory.cpp' object='pdata-PtrMemory.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pdata_CXXFLAGS) $(CXXFLAGS) -c -o pdata-PtrMemory.obj `if test -f '../../OpenFPM_devices/src/memory/PtrMemory.cpp'; then $(CYGPATH_W) '../../OpenFPM_devices/src/memory/PtrMemory.cpp'; else $(CYGPATH_W) '$(srcdir)/../../OpenFPM_devices/src/memory/PtrMemory.cpp'; fi`
pdata-VCluster.o: ../../OpenFPM_vcluster/src/VCluster.cpp
@am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pdata_CXXFLAGS) $(CXXFLAGS) -MT pdata-VCluster.o -MD -MP -MF $(DEPDIR)/pdata-VCluster.Tpo -c -o pdata-VCluster.o `test -f '../../OpenFPM_vcluster/src/VCluster.cpp' || echo '$(srcdir)/'`../../OpenFPM_vcluster/src/VCluster.cpp
@am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/pdata-VCluster.Tpo $(DEPDIR)/pdata-VCluster.Po
......@@ -545,7 +544,7 @@ distdir: $(DISTFILES)
done
check-am: all-am
check: check-am
all-am: Makefile $(PROGRAMS) config.h
all-am: Makefile $(PROGRAMS)
installdirs:
for dir in "$(DESTDIR)$(bindir)"; do \
test -z "$$dir" || $(MKDIR_P) "$$dir"; \
......@@ -588,7 +587,7 @@ distclean: distclean-am
-rm -rf ./$(DEPDIR)
-rm -f Makefile
distclean-am: clean-am distclean-compile distclean-generic \
distclean-hdr distclean-tags
distclean-tags
dvi: dvi-am
......@@ -649,21 +648,21 @@ ps-am:
uninstall-am: uninstall-binPROGRAMS
.MAKE: all install-am install-strip
.MAKE: install-am install-strip
.PHONY: CTAGS GTAGS TAGS all all-am check check-am clean \
clean-binPROGRAMS clean-generic cscopelist-am ctags ctags-am \
distclean distclean-compile distclean-generic distclean-hdr \
distclean-tags distdir dvi dvi-am html html-am info info-am \
install install-am install-binPROGRAMS install-data \
install-data-am install-dvi install-dvi-am install-exec \
install-exec-am install-html install-html-am install-info \
install-info-am install-man install-pdf install-pdf-am \
install-ps install-ps-am install-strip installcheck \
installcheck-am installdirs maintainer-clean \
maintainer-clean-generic mostlyclean mostlyclean-compile \
mostlyclean-generic pdf pdf-am ps ps-am tags tags-am uninstall \
uninstall-am uninstall-binPROGRAMS
distclean distclean-compile distclean-generic distclean-tags \
distdir dvi dvi-am html html-am info info-am install \
install-am install-binPROGRAMS install-data install-data-am \
install-dvi install-dvi-am install-exec install-exec-am \
install-html install-html-am install-info install-info-am \
install-man install-pdf install-pdf-am install-ps \
install-ps-am install-strip installcheck installcheck-am \
installdirs maintainer-clean maintainer-clean-generic \
mostlyclean mostlyclean-compile mostlyclean-generic pdf pdf-am \
ps ps-am tags tags-am uninstall uninstall-am \
uninstall-binPROGRAMS
.cu.o :
......
......@@ -13,6 +13,8 @@
#include "Vector/vector_dist_iterator.hpp"
#include "Space/Shape/Box.hpp"
#include "Vector/vector_dist_key.hpp"
#include "memory/PreAllocHeapMemory.hpp"
#include "memory/PtrMemory.hpp"
#define NO_ID false
#define ID true
......@@ -94,21 +96,39 @@ public: