ToolDAQFramework
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros
CUDA_Core.h
Go to the documentation of this file.
1 #ifndef CUDA_CORE_H
2 #define CUDA_CORE_H
3 //
4 // include files
5 //
6 
7 #include <stdlib.h>
8 #include <stdio.h>
9 #include <string.h>
10 #include <math.h>
11 #include <float.h>
12 #include <vector>
13 #include <helper_cuda.h>
14 #include <sys/time.h>
15 #include <library_daq.h>
16 
17 // CUDA = Computer Device Unified Architecture
18 
20 __global__ void kernel_correct_times_and_get_n_pmts_per_time_bin_and_direction_bin(unsigned int *ct, bool * dirs);
21 __global__ void kernel_correct_times(unsigned int *ct);
22 __global__ void kernel_histo_one_thread_one_vertex( unsigned int *ct, histogram_t *histo );
23 __global__ void kernel_histo_stride( unsigned int *ct, histogram_t *histo);
24 __global__ void kernel_histo_iterated( unsigned int *ct, histogram_t *histo, unsigned int offset );
25 __device__ int get_time_bin();
26 __device__ int get_time_bin_for_vertex_and_hit(unsigned int vertex_index, unsigned int hit_index);
27 __device__ float get_light_dx_for_vertex_and_hit(unsigned int vertex_index, unsigned int hit_index);
28 __device__ float get_light_dy_for_vertex_and_hit(unsigned int vertex_index, unsigned int hit_index);
29 __device__ float get_light_dz_for_vertex_and_hit(unsigned int vertex_index, unsigned int hit_index);
30 __device__ float get_light_dr_for_vertex_and_hit(unsigned int vertex_index, unsigned int hit_index);
31 __device__ float get_PMTx_for_hit(unsigned int hit_index);
32 __device__ float get_PMTy_for_hit(unsigned int hit_index);
33 __device__ float get_PMTz_for_hit(unsigned int hit_index);
34 __global__ void kernel_histo_stride_2d( unsigned int *ct, histogram_t *histo);
35 __global__ void kernel_histo_per_vertex( unsigned int *ct, histogram_t *histo);
36 __global__ void kernel_histo_per_vertex_shared( unsigned int *ct, histogram_t *histo);
37 __global__ void kernel_correct_times_and_get_histo_per_vertex_shared(unsigned int *ct);
38 __global__ void kernel_correct_times_and_get_histo_and_mean_position_per_vertex_shared(unsigned int *ct, float * meanx, float * meany, float * meanz);
39 __global__ void kernel_correct_times_and_get_histo_per_vertex_shared(histogram_t *ct, unsigned int* times, unsigned int* ids, unsigned short* times_of_flight,
40  unsigned int const_n_test_vertices, unsigned int const_n_time_bins, unsigned int const_n_hits,
41  unsigned int const_n_PMTs, offset_t const_time_offset, unsigned int const_time_step_size);
42 __global__ void kernel_correct_times_calculate_averages_and_get_histo_per_vertex_shared(histogram_t *ct,float *dx,float *dy,float *dz, unsigned int *ncone);
43 __global__ void kernel_nhits(unsigned int *ct, unsigned int start_time, unsigned int nhits_window);
44 
45 #endif
__global__ void kernel_correct_times_and_get_n_pmts_per_time_bin_and_direction_bin(unsigned int *ct, bool *dirs)
__global__ void kernel_histo_stride_2d(unsigned int *ct, histogram_t *histo)
__global__ void kernel_correct_times(unsigned int *ct)
unsigned short histogram_t
Definition: library_daq.h:27
__global__ void kernel_histo_one_thread_one_vertex(unsigned int *ct, histogram_t *histo)
unsigned int nhits_window
Definition: library_daq.h:212
__global__ void kernel_histo_per_vertex_shared(unsigned int *ct, histogram_t *histo)
__device__ float get_PMTx_for_hit(unsigned int hit_index)
__global__ void kernel_histo_per_vertex(unsigned int *ct, histogram_t *histo)
__device__ int get_time_bin()
__global__ void kernel_histo_stride(unsigned int *ct, histogram_t *histo)
__global__ void kernel_correct_times_calculate_averages_and_get_histo_per_vertex_shared(histogram_t *ct, float *dx, float *dy, float *dz, unsigned int *ncone)
__global__ void kernel_correct_times_and_get_n_pmts_per_time_bin(histogram_t *ct)
__global__ void kernel_nhits(unsigned int *ct, unsigned int start_time, unsigned int nhits_window)
__device__ float get_PMTy_for_hit(unsigned int hit_index)
unsigned short offset_t
Definition: library_daq.h:19
__device__ float get_light_dz_for_vertex_and_hit(unsigned int vertex_index, unsigned int hit_index)
__global__ void kernel_correct_times_and_get_histo_per_vertex_shared(unsigned int *ct)
__device__ float get_light_dy_for_vertex_and_hit(unsigned int vertex_index, unsigned int hit_index)
__global__ void kernel_histo_iterated(unsigned int *ct, histogram_t *histo, unsigned int offset)
__device__ float get_light_dx_for_vertex_and_hit(unsigned int vertex_index, unsigned int hit_index)
__device__ int get_time_bin_for_vertex_and_hit(unsigned int vertex_index, unsigned int hit_index)
__global__ void kernel_correct_times_and_get_histo_and_mean_position_per_vertex_shared(unsigned int *ct, float *meanx, float *meany, float *meanz)
__device__ float get_light_dr_for_vertex_and_hit(unsigned int vertex_index, unsigned int hit_index)
__device__ float get_PMTz_for_hit(unsigned int hit_index)