Automatic Differentiation
 
Loading...
Searching...
No Matches
buffer_types.hpp
Go to the documentation of this file.
1#ifndef STAN_MATH_OPENCL_BUFFER_TYPES_HPP
2#define STAN_MATH_OPENCL_BUFFER_TYPES_HPP
3#ifdef STAN_OPENCL
4
7#include <CL/opencl.hpp>
8
9namespace stan {
10namespace math {
11namespace opencl_kernels {
15struct in_buffer {};
16
20struct out_buffer {};
21
26struct in_out_buffer {};
27
28namespace internal {
29
38template <typename T = cl::Buffer>
39struct to_buffer {
40 using type = T;
41};
42
43template <>
45 using type = cl::Buffer;
46};
47
48template <>
50 using type = cl::Buffer;
51};
52
53template <>
55 using type = cl::Buffer;
56};
57
61template <typename T>
63} // namespace internal
64} // namespace opencl_kernels
65} // namespace math
66} // namespace stan
67
68#endif
69#endif
const typename internal::to_buffer< T >::type to_const_buffer_t
kernel_executor_opencl Alias for making const cl::Buffer argument types
The lgamma implementation in stan-math is based on either the reentrant safe lgamma_r implementation ...
Definition fvar.hpp:9
An in_buffer signifies a cl::Buffer argument used as input.
An in_out_buffer signifies a cl::Buffer argument used as both input and output.
An out_buffer signifies a cl::Buffer argument used as output.