@@ -100,36 +100,42 @@ void joint_prefetch_impl(Group g, T *ptr, size_t bytes, Properties properties) {
100
100
} // namespace detail
101
101
102
102
template <typename Properties = empty_properties_t >
103
- void prefetch (void *ptr, Properties properties = {}) {
103
+ std::enable_if_t <is_property_list_v<std::decay_t <Properties>>>
104
+ prefetch (void *ptr, Properties properties = {}) {
104
105
detail::prefetch_impl (ptr, 1 , properties);
105
106
}
106
107
107
108
template <typename Properties = empty_properties_t >
108
- void prefetch (void *ptr, size_t bytes, Properties properties = {}) {
109
+ std::enable_if_t <is_property_list_v<std::decay_t <Properties>>>
110
+ prefetch (void *ptr, size_t bytes, Properties properties = {}) {
109
111
detail::prefetch_impl (ptr, bytes, properties);
110
112
}
111
113
112
114
template <typename T, typename Properties = empty_properties_t >
113
- void prefetch (T *ptr, Properties properties = {}) {
115
+ std::enable_if_t <is_property_list_v<std::decay_t <Properties>>>
116
+ prefetch (T *ptr, Properties properties = {}) {
114
117
detail::prefetch_impl (ptr, sizeof (T), properties);
115
118
}
116
119
117
120
template <typename T, typename Properties = empty_properties_t >
118
- void prefetch (T *ptr, size_t count, Properties properties = {}) {
121
+ std::enable_if_t <is_property_list_v<std::decay_t <Properties>>>
122
+ prefetch (T *ptr, size_t count, Properties properties = {}) {
119
123
detail::prefetch_impl (ptr, count * sizeof (T), properties);
120
124
}
121
125
122
126
template <access::address_space AddressSpace, access::decorated IsDecorated,
123
127
typename Properties = empty_properties_t >
124
- std::enable_if_t <detail::check_prefetch_AS<AddressSpace>>
128
+ std::enable_if_t <detail::check_prefetch_AS<AddressSpace> &&
129
+ is_property_list_v<std::decay_t <Properties>>>
125
130
prefetch (multi_ptr<void , AddressSpace, IsDecorated> ptr,
126
131
Properties properties = {}) {
127
132
detail::prefetch_impl (ptr.get (), 1 , properties);
128
133
}
129
134
130
135
template <access::address_space AddressSpace, access::decorated IsDecorated,
131
136
typename Properties = empty_properties_t >
132
- std::enable_if_t <detail::check_prefetch_AS<AddressSpace>>
137
+ std::enable_if_t <detail::check_prefetch_AS<AddressSpace> &&
138
+ is_property_list_v<std::decay_t <Properties>>>
133
139
prefetch (multi_ptr<void , AddressSpace, IsDecorated> ptr, size_t bytes,
134
140
Properties properties = {}) {
135
141
detail::prefetch_impl (ptr.get (), bytes, properties);
@@ -138,7 +144,8 @@ prefetch(multi_ptr<void, AddressSpace, IsDecorated> ptr, size_t bytes,
138
144
template <typename T, access::address_space AddressSpace,
139
145
access::decorated IsDecorated,
140
146
typename Properties = empty_properties_t >
141
- std::enable_if_t <detail::check_prefetch_AS<AddressSpace>>
147
+ std::enable_if_t <detail::check_prefetch_AS<AddressSpace> &&
148
+ is_property_list_v<std::decay_t <Properties>>>
142
149
prefetch (multi_ptr<T, AddressSpace, IsDecorated> ptr,
143
150
Properties properties = {}) {
144
151
detail::prefetch_impl (ptr.get (), sizeof (T), properties);
@@ -147,7 +154,8 @@ prefetch(multi_ptr<T, AddressSpace, IsDecorated> ptr,
147
154
template <typename T, access::address_space AddressSpace,
148
155
access::decorated IsDecorated,
149
156
typename Properties = empty_properties_t >
150
- std::enable_if_t <detail::check_prefetch_AS<AddressSpace>>
157
+ std::enable_if_t <detail::check_prefetch_AS<AddressSpace> &&
158
+ is_property_list_v<std::decay_t <Properties>>>
151
159
prefetch (multi_ptr<T, AddressSpace, IsDecorated> ptr, size_t count,
152
160
Properties properties = {}) {
153
161
detail::prefetch_impl (ptr.get (), count * sizeof (T), properties);
@@ -157,7 +165,8 @@ template <typename DataT, int Dimensions, access_mode AccessMode,
157
165
access::placeholder IsPlaceholder,
158
166
typename Properties = empty_properties_t >
159
167
std::enable_if_t <detail::check_prefetch_acc_mode<AccessMode> &&
160
- (Dimensions > 0 )>
168
+ (Dimensions > 0 ) &&
169
+ is_property_list_v<std::decay_t <Properties>>>
161
170
prefetch (
162
171
accessor<DataT, Dimensions, AccessMode, target::device, IsPlaceholder> acc,
163
172
id<Dimensions> offset, Properties properties = {}) {
@@ -168,33 +177,38 @@ template <typename DataT, int Dimensions, access_mode AccessMode,
168
177
access::placeholder IsPlaceholder,
169
178
typename Properties = empty_properties_t >
170
179
std::enable_if_t <detail::check_prefetch_acc_mode<AccessMode> &&
171
- (Dimensions > 0 )>
180
+ (Dimensions > 0 ) &&
181
+ is_property_list_v<std::decay_t <Properties>>>
172
182
prefetch (
173
183
accessor<DataT, Dimensions, AccessMode, target::device, IsPlaceholder> acc,
174
184
size_t offset, size_t count, Properties properties = {}) {
175
185
detail::prefetch_impl (&acc[offset], count * sizeof (DataT), properties);
176
186
}
177
187
178
188
template <typename Group, typename Properties = empty_properties_t >
179
- std::enable_if_t <sycl::is_group_v<std::decay_t <Group>>>
189
+ std::enable_if_t <sycl::is_group_v<std::decay_t <Group>> &&
190
+ is_property_list_v<std::decay_t <Properties>>>
180
191
joint_prefetch (Group g, void *ptr, Properties properties = {}) {
181
192
detail::joint_prefetch_impl (g, ptr, 1 , properties);
182
193
}
183
194
184
195
template <typename Group, typename Properties = empty_properties_t >
185
- std::enable_if_t <sycl::is_group_v<std::decay_t <Group>>>
196
+ std::enable_if_t <sycl::is_group_v<std::decay_t <Group>> &&
197
+ is_property_list_v<std::decay_t <Properties>>>
186
198
joint_prefetch (Group g, void *ptr, size_t bytes, Properties properties = {}) {
187
199
detail::joint_prefetch_impl (g, ptr, bytes, properties);
188
200
}
189
201
190
202
template <typename Group, typename T, typename Properties = empty_properties_t >
191
- std::enable_if_t <sycl::is_group_v<std::decay_t <Group>>>
203
+ std::enable_if_t <sycl::is_group_v<std::decay_t <Group>> &&
204
+ is_property_list_v<std::decay_t <Properties>>>
192
205
joint_prefetch (Group g, T *ptr, Properties properties = {}) {
193
206
detail::joint_prefetch_impl (g, ptr, sizeof (T), properties);
194
207
}
195
208
196
209
template <typename Group, typename T, typename Properties = empty_properties_t >
197
- std::enable_if_t <sycl::is_group_v<std::decay_t <Group>>>
210
+ std::enable_if_t <sycl::is_group_v<std::decay_t <Group>> &&
211
+ is_property_list_v<std::decay_t <Properties>>>
198
212
joint_prefetch (Group g, T *ptr, size_t count, Properties properties = {}) {
199
213
detail::joint_prefetch_impl (g, ptr, count * sizeof (T), properties);
200
214
}
@@ -203,7 +217,8 @@ template <typename Group, access::address_space AddressSpace,
203
217
access::decorated IsDecorated,
204
218
typename Properties = empty_properties_t >
205
219
std::enable_if_t <detail::check_prefetch_AS<AddressSpace> &&
206
- sycl::is_group_v<std::decay_t <Group>>>
220
+ sycl::is_group_v<std::decay_t <Group>> &&
221
+ is_property_list_v<std::decay_t <Properties>>>
207
222
joint_prefetch (Group g, multi_ptr<void , AddressSpace, IsDecorated> ptr,
208
223
Properties properties = {}) {
209
224
detail::joint_prefetch_impl (g, ptr.get (), 1 , properties);
@@ -213,7 +228,8 @@ template <typename Group, access::address_space AddressSpace,
213
228
access::decorated IsDecorated,
214
229
typename Properties = empty_properties_t >
215
230
std::enable_if_t <detail::check_prefetch_AS<AddressSpace> &&
216
- sycl::is_group_v<std::decay_t <Group>>>
231
+ sycl::is_group_v<std::decay_t <Group>> &&
232
+ is_property_list_v<std::decay_t <Properties>>>
217
233
joint_prefetch (Group g, multi_ptr<void , AddressSpace, IsDecorated> ptr,
218
234
size_t bytes, Properties properties = {}) {
219
235
detail::joint_prefetch_impl (g, ptr.get (), bytes, properties);
@@ -223,7 +239,8 @@ template <typename Group, typename T, access::address_space AddressSpace,
223
239
access::decorated IsDecorated,
224
240
typename Properties = empty_properties_t >
225
241
std::enable_if_t <detail::check_prefetch_AS<AddressSpace> &&
226
- sycl::is_group_v<std::decay_t <Group>>>
242
+ sycl::is_group_v<std::decay_t <Group>> &&
243
+ is_property_list_v<std::decay_t <Properties>>>
227
244
joint_prefetch (Group g, multi_ptr<T, AddressSpace, IsDecorated> ptr,
228
245
Properties properties = {}) {
229
246
detail::joint_prefetch_impl (g, ptr.get (), sizeof (T), properties);
@@ -233,7 +250,8 @@ template <typename Group, typename T, access::address_space AddressSpace,
233
250
access::decorated IsDecorated,
234
251
typename Properties = empty_properties_t >
235
252
std::enable_if_t <detail::check_prefetch_AS<AddressSpace> &&
236
- sycl::is_group_v<std::decay_t <Group>>>
253
+ sycl::is_group_v<std::decay_t <Group>> &&
254
+ is_property_list_v<std::decay_t <Properties>>>
237
255
joint_prefetch (Group g, multi_ptr<T, AddressSpace, IsDecorated> ptr,
238
256
size_t count, Properties properties = {}) {
239
257
detail::joint_prefetch_impl (g, ptr.get (), count * sizeof (T), properties);
@@ -243,7 +261,8 @@ template <typename Group, typename DataT, int Dimensions,
243
261
access_mode AccessMode, access::placeholder IsPlaceholder,
244
262
typename Properties = empty_properties_t >
245
263
std::enable_if_t <detail::check_prefetch_acc_mode<AccessMode> &&
246
- (Dimensions > 0 ) && sycl::is_group_v<std::decay_t <Group>>>
264
+ (Dimensions > 0 ) && sycl::is_group_v<std::decay_t <Group>> &&
265
+ is_property_list_v<std::decay_t <Properties>>>
247
266
joint_prefetch (
248
267
Group g,
249
268
accessor<DataT, Dimensions, AccessMode, target::device, IsPlaceholder> acc,
@@ -255,7 +274,8 @@ template <typename Group, typename DataT, int Dimensions,
255
274
access_mode AccessMode, access::placeholder IsPlaceholder,
256
275
typename Properties = empty_properties_t >
257
276
std::enable_if_t <detail::check_prefetch_acc_mode<AccessMode> &&
258
- (Dimensions > 0 ) && sycl::is_group_v<std::decay_t <Group>>>
277
+ (Dimensions > 0 ) && sycl::is_group_v<std::decay_t <Group>> &&
278
+ is_property_list_v<std::decay_t <Properties>>>
259
279
joint_prefetch (
260
280
Group g,
261
281
accessor<DataT, Dimensions, AccessMode, target::device, IsPlaceholder> acc,
0 commit comments