1#define PRINT_STACKTRACE
9#include "util/print_stack.hpp"
10#include "util/math_util_complex.hpp"
12Vcluster<> * global_v_cluster_private_heap = NULL;
16std::vector<int> sieve_spf;
20bool ofp_initialized =
false;
41std::string program_name;
45#include "memory/CudaMemory.cuh"
58void bt_sighandler(
int sig, siginfo_t * info,
void * ctx_p)
61 std::cout <<
"Got signal " << sig <<
" faulty address is %p, " << info->si_addr <<
" from " << info->si_pid << std::endl;
63 std:: cout <<
"Got signal " << sig << std::endl;
70double time_spent = 0.0;
78void openfpm_init_vcl(
int *argc,
char ***argv)
83 PetscInitialize(argc,argv,NULL,NULL);
87 init_global_v_cluster_private(argc,argv);
90 std::cout <<
"OpenFPM is compiled with debug mode LEVEL:1. Remember to remove SE_CLASS1 when you go in production" << std::endl;
94 std::cout <<
"OpenFPM is compiled with debug mode LEVEL:2. Remember to remove SE_CLASS2 when you go in production" << std::endl;
98 std::cout <<
"OpenFPM is compiled with debug mode LEVEL:3. Remember to remove SE_CLASS3 when you go in production" << std::endl;
107 sa.sa_sigaction = bt_sighandler;
108 sigemptyset(&sa.sa_mask);
109 sa.sa_flags = SA_RESTART;
111 sigaction(SIGSEGV, &sa, NULL);
113 if (argc != NULL && *argc != 0)
114 {program_name = std::string(*argv[0]);}
117 openfpm::math::init_getFactorization();
119 ofp_initialized =
true;
128 for (
int i = 0 ; i < MAX_NUMER_OF_PROPERTIES ; i++)
137size_t openfpm_vcluster_compilation_mask()
139 size_t compiler_mask = CUDA_ON_BACKEND;
141 return compiler_mask;
149void openfpm_finalize()
157 delete_global_v_cluster_private();
158 ofp_initialized =
false;
169 for (
int i = 0 ; i < MAX_NUMER_OF_PROPERTIES ; i++)
virtual void incRef()
Increment the reference counter.
virtual void decRef()
Decrement the reference counter.
virtual void destroy()
destroy memory
Implementation of VCluster class.