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
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
#![doc(html_root_url = "https://docs.rs/ocl/0.13")]
extern crate libc;
extern crate num;
#[cfg(test)]
extern crate rand;
extern crate futures;
extern crate crossbeam;
pub extern crate ocl_core as core;
#[cfg(test)]
mod tests;
mod standard;
pub mod async;
pub use self::standard::{Platform, Device, Context, Program, Queue, Kernel, Buffer, Image, Event,
EventList, EventArray, Sampler, SpatialDims, ProQue};
pub use self::async::{MemMap, FutureMemMap, RwVec, ReadGuard, WriteGuard, FutureRwGuard,
FutureReader, FutureWriter};
pub use core::error::{Error, Result};
#[doc(no_inline)]
pub use core::ffi;
#[doc(no_inline)]
pub use core::util;
#[doc(no_inline)]
pub use core::{OclPrm, OclScl, OclVec, DeviceType, CommandQueueProperties, MemFlags, MapFlags};
pub mod prm {
pub use ffi::{cl_char, cl_uchar, cl_short, cl_ushort, cl_int, cl_uint, cl_long, cl_ulong,
cl_half, cl_float, cl_double, cl_bool, cl_bitfield};
pub use ffi::{ cl_GLuint, cl_GLint, cl_GLenum };
pub use core::{
Char, Char2, Char3, Char4, Char8, Char16,
Uchar, Uchar2, Uchar3, Uchar4, Uchar8, Uchar16,
Short, Short2, Short3, Short4, Short8, Short16,
Ushort, Ushort2, Ushort3, Ushort4, Ushort8, Ushort16,
Int, Int2, Int3, Int4, Int8, Int16,
Uint, Uint2, Uint3, Uint4, Uint8, Uint16,
Long, Long2, Long3, Long4, Long8, Long16,
Ulong, Ulong2, Ulong3, Ulong4, Ulong8, Ulong16,
Float, Float2, Float3, Float4, Float8, Float16,
Double, Double2, Double3, Double4, Double8, Double16};
}
pub mod traits {
pub use standard::{WorkDims, MemLen, IntoMarker, IntoRawEventArray};
pub use core::{OclPrm, OclScl, OclVec};
}
pub mod builders {
pub use standard::{ContextBuilder, BuildOpt, ProgramBuilder, ImageBuilder, ProQueBuilder,
DeviceSpecifier, BufferCmdKind, BufferCmdDataShape, BufferCmd, BufferReadCmd,
BufferWriteCmd, BufferMapCmd, ImageCmdKind, ImageCmd, KernelCmd, BufferBuilder};
pub use standard::{ClNullEventPtrEnum, ClWaitListPtrEnum};
pub use core::{ImageFormat, ImageDescriptor, ContextProperties};
}
pub mod flags {
pub use core::{
DeviceType, DEVICE_TYPE_DEFAULT, DEVICE_TYPE_CPU, DEVICE_TYPE_GPU, DEVICE_TYPE_ACCELERATOR,
DEVICE_TYPE_CUSTOM, DEVICE_TYPE_ALL,
DeviceFpConfig, FP_DENORM, FP_INF_NAN, FP_ROUND_TO_NEAREST, FP_ROUND_TO_ZERO,
FP_ROUND_TO_INF, FP_FMA, FP_SOFT_FLOAT, FP_CORRECTLY_ROUNDED_DIVIDE_SQRT,
DeviceExecCapabilities, EXEC_KERNEL, EXEC_NATIVE_KERNEL,
CommandQueueProperties, QUEUE_OUT_OF_ORDER_EXEC_MODE_ENABLE, QUEUE_PROFILING_ENABLE,
DeviceAffinityDomain, DEVICE_AFFINITY_DOMAIN_NUMA, DEVICE_AFFINITY_DOMAIN_L4_CACHE,
DEVICE_AFFINITY_DOMAIN_L3_CACHE, DEVICE_AFFINITY_DOMAIN_L2_CACHE,
DEVICE_AFFINITY_DOMAIN_L1_CACHE, DEVICE_AFFINITY_DOMAIN_NEXT_PARTITIONABLE,
MemFlags, MEM_READ_WRITE, MEM_WRITE_ONLY, MEM_READ_ONLY, MEM_USE_HOST_PTR,
MEM_ALLOC_HOST_PTR, MEM_COPY_HOST_PTR, MEM_HOST_WRITE_ONLY, MEM_HOST_READ_ONLY,
MEM_HOST_NO_ACCESS,
MemMigrationFlags, MIGRATE_MEM_OBJECT_HOST, MIGRATE_MEM_OBJECT_CONTENT_UNDEFINED,
MapFlags, MAP_READ, MAP_WRITE, MAP_WRITE_INVALIDATE_REGION,
ProgramBinaryType, PROGRAM_BINARY_TYPE_NONE, PROGRAM_BINARY_TYPE_COMPILED_OBJECT,
PROGRAM_BINARY_TYPE_LIBRARY, PROGRAM_BINARY_TYPE_EXECUTABLE,
KernelArgTypeQualifier, KERNEL_ARG_TYPE_NONE, KERNEL_ARG_TYPE_CONST,
KERNEL_ARG_TYPE_RESTRICT, KERNEL_ARG_TYPE_VOLATILE,
};
}
pub mod enums {
pub use standard::{DeviceSpecifier, BufferCmdKind, BufferCmdDataShape};
pub use core::{ImageChannelOrder, ImageChannelDataType, Cbool, Polling, PlatformInfo,
DeviceInfo, DeviceMemCacheType, DeviceLocalMemType, ContextInfo, ContextProperty,
ContextInfoOrPropertiesPointerType, DevicePartitionProperty, CommandQueueInfo, ChannelType,
MemObjectType, MemInfo, ImageInfo, AddressingMode, FilterMode, SamplerInfo, ProgramInfo,
ProgramBuildInfo, ProgramBuildStatus, KernelInfo, KernelArgInfo, KernelArgAddressQualifier,
KernelArgAccessQualifier, KernelWorkGroupInfo, EventInfo, CommandType,
CommandExecutionStatus, BufferCreateType, ProfilingInfo};
pub use core::{KernelArg, ContextPropertyValue, PlatformInfoResult, DeviceInfoResult,
ContextInfoResult, CommandQueueInfoResult, MemInfoResult, ImageInfoResult,
SamplerInfoResult, ProgramInfoResult, ProgramBuildInfoResult, KernelInfoResult,
KernelArgInfoResult, KernelWorkGroupInfoResult, EventInfoResult, ProfilingInfoResult};
pub use core::Status;
}