forked from MichaelSt98/milupHPC
-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathsimulation_time.cuh
More file actions
46 lines (36 loc) · 1.26 KB
/
simulation_time.cuh
File metadata and controls
46 lines (36 loc) · 1.26 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
/**
* @file simulation_time.cuh
* @brief Simulation time related variables and functions instantiable on device and host.
*
* @author Michael Staneker
* @bug no known bugs
*/
#ifndef MILUPHPC_SIMULATIONTIME_CUH
#define MILUPHPC_SIMULATIONTIME_CUH
#include "parameter.h"
#include "cuda_utils/cuda_utilities.cuh"
class SimulationTime {
public:
real *dt;
real *startTime;
real *subEndTime;
real *endTime;
real *currentTime;
real *dt_max;
CUDA_CALLABLE_MEMBER SimulationTime();
CUDA_CALLABLE_MEMBER SimulationTime(real *startTime, real *endTime, real *dt);
CUDA_CALLABLE_MEMBER ~SimulationTime();
CUDA_CALLABLE_MEMBER void set(real *dt, real *startTime, real *subEndTime, real *endTime,
real *currentTime, real *dt_max);
};
namespace SimulationTimeNS {
namespace Kernel {
__global__ void set(SimulationTime *simulationTime, real *dt, real *startTime, real *subEndTime, real *endTime,
real *currentTime, real *dt_max);
namespace Launch {
void set(SimulationTime *simulationTime, real *dt, real *startTime, real *subEndTime, real *endTime,
real *currentTime, real *dt_max);
}
}
}
#endif //MILUPHPC_SIMULATIONTIME_CUH