1
0
mirror of https://github.com/paboyle/Grid.git synced 2024-11-10 15:55:37 +00:00

Namespace

This commit is contained in:
paboyle 2018-01-12 23:28:01 +00:00
parent 68b69a2ac0
commit e6f7a5a818

View File

@ -1,4 +1,4 @@
/************************************************************************************* /*************************************************************************************
Grid physics library, www.github.com/paboyle/Grid Grid physics library, www.github.com/paboyle/Grid
@ -24,43 +24,43 @@ Author: paboyle <paboyle@ph.ed.ac.uk>
51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
See the full license in the file "LICENSE" in the top level distribution directory See the full license in the file "LICENSE" in the top level distribution directory
*************************************************************************************/ *************************************************************************************/
/* END LEGAL */ /* END LEGAL */
#ifndef GRID_INIT_H #ifndef GRID_INIT_H
#define GRID_INIT_H #define GRID_INIT_H
namespace Grid { NAMESPACE_BEGIN(Grid);
void Grid_init(int *argc,char ***argv); void Grid_init(int *argc,char ***argv);
void Grid_finalize(void); void Grid_finalize(void);
// internal, controled with --handle // internal, controled with --handle
void Grid_sa_signal_handler(int sig,siginfo_t *si,void * ptr); void Grid_sa_signal_handler(int sig,siginfo_t *si,void * ptr);
void Grid_debug_handler_init(void); void Grid_debug_handler_init(void);
void Grid_quiesce_nodes(void); void Grid_quiesce_nodes(void);
void Grid_unquiesce_nodes(void); void Grid_unquiesce_nodes(void);
const std::vector<int> GridDefaultSimd(int dims,int nsimd); const std::vector<int> GridDefaultSimd(int dims,int nsimd);
const std::vector<int> &GridDefaultLatt(void); const std::vector<int> &GridDefaultLatt(void);
const std::vector<int> &GridDefaultMpi(void); const std::vector<int> &GridDefaultMpi(void);
const int &GridThreads(void) ; const int &GridThreads(void) ;
void GridSetThreads(int t) ; void GridSetThreads(int t) ;
void GridLogTimestamp(int); void GridLogTimestamp(int);
void GridLogLayout(); void GridLogLayout();
// Common parsing chores // Common parsing chores
std::string GridCmdOptionPayload(char ** begin, char ** end, const std::string & option); std::string GridCmdOptionPayload(char ** begin, char ** end, const std::string & option);
bool GridCmdOptionExists(char** begin, char** end, const std::string& option); bool GridCmdOptionExists(char** begin, char** end, const std::string& option);
std::string GridCmdVectorIntToString(const std::vector<int> & vec); std::string GridCmdVectorIntToString(const std::vector<int> & vec);
void GridCmdOptionCSL(std::string str,std::vector<std::string> & vec); void GridCmdOptionCSL(std::string str,std::vector<std::string> & vec);
void GridCmdOptionIntVector(std::string &str,std::vector<int> & vec); void GridCmdOptionIntVector(std::string &str,std::vector<int> & vec);
void GridParseLayout(char **argv,int argc, void GridParseLayout(char **argv,int argc,
std::vector<int> &latt, std::vector<int> &latt,
std::vector<int> &simd, std::vector<int> &simd,
std::vector<int> &mpi); std::vector<int> &mpi);
NAMESPACE_END(Grid);
};
#endif #endif