From cbb232dcb9dc1af5d5787b22185ea56f3884a136 Mon Sep 17 00:00:00 2001 From: Dongryeol Lee Date: Sat, 22 Jan 2011 02:54:36 +0000 Subject: [PATCH] Some more changes, now onto new parallel tree building. --- .../dongryel/thesis_research/core/table/global.cc | 11 ++++++++--- .../dongryel/thesis_research/core/table/index_util.h | 7 +++++-- .../thesis_research/core/table/memory_mapped_file.h | 6 ++++-- .../thesis_research/core/table/sub_dense_matrix.h | 4 ++-- .../dongryel/thesis_research/core/table/transform.h | 4 ++-- .../thesis_research/core/tree/general_spacetree.h | 10 ++++++++-- .../physpack/nbody_simulator/axilrod_teller.h | 4 ++-- .../physpack/nbody_simulator/nbody_simulator.h | 4 ++-- .../physpack/nbody_simulator/nbody_simulator.test.cc | 4 ++-- .../nbody_simulator/nbody_simulator_arguments.h | 4 ++-- .../nbody_simulator/nbody_simulator_tripletree.h | 4 ++-- 11 files changed, 39 insertions(+), 23 deletions(-) diff --git a/fastlib/trunk/contrib/dongryel/thesis_research/core/table/global.cc b/fastlib/trunk/contrib/dongryel/thesis_research/core/table/global.cc index c28b6e0279..4ad31bd873 100644 --- a/fastlib/trunk/contrib/dongryel/thesis_research/core/table/global.cc +++ b/fastlib/trunk/contrib/dongryel/thesis_research/core/table/global.cc @@ -1,12 +1,17 @@ /** @file global.cc + * + * An instantiation of global memory mapped file object. * * @author Dongryeol Lee (dongryel@cc.gatech.edu) */ -#include "memory_mapped_file.h" +#include "core/table/memory_mapped_file.h" namespace core { namespace table { + +/** @brief A global memory mapped file object. + */ core::table::MemoryMappedFile *global_m_file_ = NULL; -}; -}; +} +} diff --git a/fastlib/trunk/contrib/dongryel/thesis_research/core/table/index_util.h b/fastlib/trunk/contrib/dongryel/thesis_research/core/table/index_util.h index 33bc9d4b14..80f1ea31f0 100644 --- a/fastlib/trunk/contrib/dongryel/thesis_research/core/table/index_util.h +++ b/fastlib/trunk/contrib/dongryel/thesis_research/core/table/index_util.h @@ -1,4 +1,7 @@ /** @file index_util.h + * + * A set of utilities for serializing/unserializing indices for + * maintaining the mapping order in shuffled points in a table. * * @author Dongryeol Lee (dongryel@cc.gatech.edu) */ @@ -97,7 +100,7 @@ class IndexUtil< std::pair > > { } } }; -}; -}; +} +} #endif diff --git a/fastlib/trunk/contrib/dongryel/thesis_research/core/table/memory_mapped_file.h b/fastlib/trunk/contrib/dongryel/thesis_research/core/table/memory_mapped_file.h index 723a1786b9..b8c6e04747 100644 --- a/fastlib/trunk/contrib/dongryel/thesis_research/core/table/memory_mapped_file.h +++ b/fastlib/trunk/contrib/dongryel/thesis_research/core/table/memory_mapped_file.h @@ -1,4 +1,6 @@ /** @file memory_mapped_file.h + * + * A declaration of memory mapped file object class. * * @author Dongryeol Lee (dongryel@cc.gatech.edu) */ @@ -84,7 +86,7 @@ class MemoryMappedFile { boost::interprocess::anonymous_instance)[num_elements_in](); } }; -}; -}; +} +} #endif diff --git a/fastlib/trunk/contrib/dongryel/thesis_research/core/table/sub_dense_matrix.h b/fastlib/trunk/contrib/dongryel/thesis_research/core/table/sub_dense_matrix.h index 4e4de9dc35..7a0d97a93a 100644 --- a/fastlib/trunk/contrib/dongryel/thesis_research/core/table/sub_dense_matrix.h +++ b/fastlib/trunk/contrib/dongryel/thesis_research/core/table/sub_dense_matrix.h @@ -93,7 +93,7 @@ class SubDenseMatrix { } BOOST_SERIALIZATION_SPLIT_MEMBER() }; -}; -}; +} +} #endif diff --git a/fastlib/trunk/contrib/dongryel/thesis_research/core/table/transform.h b/fastlib/trunk/contrib/dongryel/thesis_research/core/table/transform.h index 1ef0d71063..0e4c204535 100644 --- a/fastlib/trunk/contrib/dongryel/thesis_research/core/table/transform.h +++ b/fastlib/trunk/contrib/dongryel/thesis_research/core/table/transform.h @@ -47,7 +47,7 @@ class Standardize { } } }; -}; -}; +} +} #endif diff --git a/fastlib/trunk/contrib/dongryel/thesis_research/core/tree/general_spacetree.h b/fastlib/trunk/contrib/dongryel/thesis_research/core/tree/general_spacetree.h index 3099351e6a..0f104e4bf1 100644 --- a/fastlib/trunk/contrib/dongryel/thesis_research/core/tree/general_spacetree.h +++ b/fastlib/trunk/contrib/dongryel/thesis_research/core/tree/general_spacetree.h @@ -26,6 +26,8 @@ extern core::table::MemoryMappedFile *global_m_file_; namespace core { namespace tree { +/** @brief The utility to initialize old_from_new indices. + */ template class IndexInitializer { public: @@ -43,6 +45,9 @@ class IndexInitializer { int *new_from_old_out); }; +/** @brief The template specialization of IndexInitializer for the + * distributed table setting. + */ template<> class IndexInitializer< std::pair > > { public: @@ -73,6 +78,9 @@ class IndexInitializer< std::pair > > { } }; +/** @brief The template specialization of IndexInitializer for the + * ordinary table setting. + */ template<> class IndexInitializer< int > { public: @@ -524,8 +532,6 @@ class GeneralBinarySpaceTree { } if(left > right) { - - // left == right + 1 break; } diff --git a/fastlib/trunk/contrib/dongryel/thesis_research/physpack/nbody_simulator/axilrod_teller.h b/fastlib/trunk/contrib/dongryel/thesis_research/physpack/nbody_simulator/axilrod_teller.h index 78b0be1d05..09bcaa7eb4 100644 --- a/fastlib/trunk/contrib/dongryel/thesis_research/physpack/nbody_simulator/axilrod_teller.h +++ b/fastlib/trunk/contrib/dongryel/thesis_research/physpack/nbody_simulator/axilrod_teller.h @@ -161,7 +161,7 @@ class AxilrodTeller { return numerator / denominator / normalizing_constant_; } }; -}; -}; +} +} #endif diff --git a/fastlib/trunk/contrib/dongryel/thesis_research/physpack/nbody_simulator/nbody_simulator.h b/fastlib/trunk/contrib/dongryel/thesis_research/physpack/nbody_simulator/nbody_simulator.h index 65f55bc787..e17a6de144 100644 --- a/fastlib/trunk/contrib/dongryel/thesis_research/physpack/nbody_simulator/nbody_simulator.h +++ b/fastlib/trunk/contrib/dongryel/thesis_research/physpack/nbody_simulator/nbody_simulator.h @@ -81,7 +81,7 @@ class NbodySimulator { const std::vector &args, boost::program_options::variables_map *vm); }; -}; -}; +} +} #endif diff --git a/fastlib/trunk/contrib/dongryel/thesis_research/physpack/nbody_simulator/nbody_simulator.test.cc b/fastlib/trunk/contrib/dongryel/thesis_research/physpack/nbody_simulator/nbody_simulator.test.cc index f10831c6fe..492bec3670 100644 --- a/fastlib/trunk/contrib/dongryel/thesis_research/physpack/nbody_simulator/nbody_simulator.test.cc +++ b/fastlib/trunk/contrib/dongryel/thesis_research/physpack/nbody_simulator/nbody_simulator.test.cc @@ -193,8 +193,8 @@ class TestNbodySimulator { return 0; }; }; -}; -}; +} +} BOOST_AUTO_TEST_SUITE(TestSuiteNbodySimulator) BOOST_AUTO_TEST_CASE(TestCaseNbodySimulator) { diff --git a/fastlib/trunk/contrib/dongryel/thesis_research/physpack/nbody_simulator/nbody_simulator_arguments.h b/fastlib/trunk/contrib/dongryel/thesis_research/physpack/nbody_simulator/nbody_simulator_arguments.h index 0d75238660..beca9ac5a5 100644 --- a/fastlib/trunk/contrib/dongryel/thesis_research/physpack/nbody_simulator/nbody_simulator_arguments.h +++ b/fastlib/trunk/contrib/dongryel/thesis_research/physpack/nbody_simulator/nbody_simulator_arguments.h @@ -52,7 +52,7 @@ class NbodySimulatorArguments { } } }; -}; -}; +} +} #endif diff --git a/fastlib/trunk/contrib/dongryel/thesis_research/physpack/nbody_simulator/nbody_simulator_tripletree.h b/fastlib/trunk/contrib/dongryel/thesis_research/physpack/nbody_simulator/nbody_simulator_tripletree.h index 78b5957205..3f1a42ecf1 100644 --- a/fastlib/trunk/contrib/dongryel/thesis_research/physpack/nbody_simulator/nbody_simulator_tripletree.h +++ b/fastlib/trunk/contrib/dongryel/thesis_research/physpack/nbody_simulator/nbody_simulator_tripletree.h @@ -870,7 +870,7 @@ class NbodySimulatorStatistic: public boost::noncopyable { SetZero(); } }; -}; -}; +} +} #endif