1 #ifndef OCL_PROVIDER_INC
2 #define OCL_PROVIDER_INC
4 #define __CL_ENABLE_EXCEPTIONS
6 #ifndef SPATIALSEIR_INCLUDEFILES
7 #define SPATIALSEIR_INCLUDEFILES
23 struct P_SE_Calculation_KernelData
31 struct FC_R_Star_KernelData
43 DeviceContainer(cl::Device *inDevice, cl::Context *inContext);
46 cl::CommandQueue * commandQueue;
49 class PlatformContainer
52 PlatformContainer(cl::Platform *inPlatform);
55 cl::Platform **platform;
57 std::vector<DeviceContainer*> *devices;
58 std::vector<std::string> *deviceTypes;
59 std::vector<std::string> *deviceNames;
60 std::vector<cl_uint> *doublePrecision;
68 void setDevice(
int platformId,
int deviceId);
75 cl::Platform **currentPlatform;
76 cl::Context **currentContext;
77 DeviceContainer **currentDevice;
80 std::vector<PlatformContainer*> *platforms;
81 cl::Kernel buildProgramForKernel(std::string kernelFile,
82 DeviceContainer *device);
83 std::vector<cl::Program> *programs;
84 FC_R_Star_KernelData* R_star_args;
85 P_SE_Calculation_KernelData* p_se_args;
104 cl::Kernel* test_kernel;
105 cl::Kernel* R_Star_kernel;
106 cl::Kernel* p_se_kernel1;
107 cl::Kernel* p_se_kernel2;
111 cl::CommandQueue* cpuQueue;
112 cl::CommandQueue* gpuQueue;
119 #ifndef ENABLE_OPEN_CL
121 namespace SpatialSEIR
128 void setDevice(
int platformId,
int deviceId);
void setDevice(int platformId, int deviceId)
Definition: OCLProvider.cpp:346
double FC_R_Star(int nLoc, int nTpts, int *S_star, int *E_star, int *R_star, int *S, int *I, int *R, double *p_se, double *p_rs, double *p_ir)
Definition: OCLFunctions.cpp:303
~OCLProvider()
Definition: OCLProvider.cpp:379
OCLProvider()
Definition: OCLProvider.cpp:341
Definition: OCLProvider.hpp:123
void calculateP_SE(ModelContext *ctx)
Definition: OCLFunctions.cpp:22
void printSummary()
Definition: OCLProvider.cpp:352
int test()
Definition: OCLFunctions.cpp:463
Definition: ModelContext.hpp:82