14 inline namespace _V1 {
17 namespace experimental {
19 template <
typename T,
typename ListA,
typename ListB>
24 template <
typename PropertyListT>
42 typename propertyListB =
49 const propertyListA &propList =
properties{}) {
51 sycl::usm::alloc::host, propList);
52 return annotated_ptr<void, propertyListB>(tmp.get());
56 typename propertyListB =
57 typename GetAnnotatedHostPtrProperties<propertyListA>::type>
59 CheckHostPtrTAndPropLists<T, propertyListA, propertyListB>::value,
60 annotated_ptr<T, propertyListB>>
63 const propertyListA &propList =
properties{}) {
64 auto tmp = aligned_alloc_annotated<T>(
alignment, count, {}, syclContext,
65 sycl::usm::alloc::host, propList);
66 return annotated_ptr<T, propertyListB>(tmp.get());
70 typename propertyListB =
71 typename GetAnnotatedHostPtrProperties<propertyListA>::type>
73 CheckHostPtrTAndPropLists<void, propertyListA, propertyListB>::value,
74 annotated_ptr<void, propertyListB>>
76 const queue &syclQueue,
77 const propertyListA &propList =
properties{}) {
83 typename propertyListB =
84 typename GetAnnotatedHostPtrProperties<propertyListA>::type>
86 CheckHostPtrTAndPropLists<T, propertyListA, propertyListB>::value,
87 annotated_ptr<T, propertyListB>>
89 const queue &syclQueue,
90 const propertyListA &propList =
properties{}) {
91 return aligned_alloc_host_annotated<T>(
alignment, count,
103 typename propertyListB =
104 typename GetAnnotatedHostPtrProperties<propertyListA>::type>
106 CheckHostPtrTAndPropLists<void, propertyListA, propertyListB>::value,
107 annotated_ptr<void, propertyListB>>
109 const propertyListA &propList =
properties{}) {
114 typename propertyListB =
115 typename GetAnnotatedHostPtrProperties<propertyListA>::type>
117 CheckHostPtrTAndPropLists<T, propertyListA, propertyListB>::value,
118 annotated_ptr<T, propertyListB>>
120 const propertyListA &propList =
properties{}) {
121 return aligned_alloc_host_annotated<T>(0, count, syclContext, propList);
125 typename propertyListB =
126 typename GetAnnotatedHostPtrProperties<propertyListA>::type>
128 CheckHostPtrTAndPropLists<void, propertyListA, propertyListB>::value,
129 annotated_ptr<void, propertyListB>>
131 const propertyListA &propList =
properties{}) {
136 typename propertyListB =
137 typename GetAnnotatedHostPtrProperties<propertyListA>::type>
139 CheckHostPtrTAndPropLists<T, propertyListA, propertyListB>::value,
140 annotated_ptr<T, propertyListB>>
142 const propertyListA &propList =
properties{}) {
143 return malloc_host_annotated<T>(count, syclQueue.
get_context(), propList);
The context class represents a SYCL context on which kernel functions may be executed.
Encapsulates a single SYCL queue which schedules kernels on a SYCL device.
context get_context() const
properties< std::tuple<> > empty_properties_t
constexpr alignment_key::value_t< K > alignment
std::enable_if_t< CheckHostPtrTAndPropLists< void, propertyListA, propertyListB >::value, annotated_ptr< void, propertyListB > > aligned_alloc_host_annotated(size_t alignment, size_t numBytes, const context &syclContext, const propertyListA &propList=properties{})
typename detail::CheckTAndPropListsWithUsmKind< sycl::usm::alloc::host, T, ListA, ListB > CheckHostPtrTAndPropLists
std::enable_if_t< detail::CheckTAndPropLists< void, propertyListA, propertyListB >::value, annotated_ptr< void, propertyListB > > aligned_alloc_annotated(size_t alignment, size_t numBytes, const device &syclDevice, const context &syclContext, sycl::usm::alloc kind, const propertyListA &propList=properties{})
std::enable_if_t< CheckHostPtrTAndPropLists< void, propertyListA, propertyListB >::value, annotated_ptr< void, propertyListB > > malloc_host_annotated(size_t numBytes, const context &syclContext, const propertyListA &propList=properties{})