You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: sycl/doc/extensions/supported/sycl_ext_intel_dataflow_pipes.asciidoc
+42-42Lines changed: 42 additions & 42 deletions
Original file line number
Diff line number
Diff line change
@@ -110,9 +110,9 @@ A pipe type is a specialization of the pipe class:
110
110
111
111
[source,c++,Pipe type def,linenums]
112
112
----
113
-
template <typename name,
114
-
typename dataT,
115
-
size_t min_capacity = 0>
113
+
template <typename _name,
114
+
typename _dataT,
115
+
size_t _min_capacity = 0>
116
116
class pipe;
117
117
----
118
118
@@ -131,7 +131,7 @@ using pipe<class bar, float, 5>;
131
131
132
132
The interface of a pipe is through static member functions, and instances of a pipe class cannot be instantiated. Allowing instances of pipe objects, when their type defines connectivity, would introduce an error prone secondary mechanism of reference.
133
133
134
-
The first template parameter, `name`, can be any type, and is typically expected to be a user defined class in a user namespace. The type only needs to be forward declared, and not defined.
134
+
The first template parameter, `_name`, can be any type, and is typically expected to be a user defined class in a user namespace. The type only needs to be forward declared, and not defined.
135
135
136
136
Above this basic mechanism of {cpp} type being used to identify a pipe, additional layers can be built on top to contain the type in an object that can be passed by value. Because such mechanisms (e.g. `boost::hana::type`) can layer on top of the fundamental type-based mechanism described here, those mechanisms are not included in the extension specification.
== Read/write member functions, and pipe template parameters
168
168
169
-
The pipe class exposes static member functions for writing a data word to a pipe, and for reading a data word from a pipe. A data word in this context is the data type that the pipe contains (`dataT` pipe template argument).
169
+
The pipe class exposes static member functions for writing a data word to a pipe, and for reading a data word from a pipe. A data word in this context is the data type that the pipe contains (`_dataT` pipe template argument).
170
170
171
171
Blocking and non-blocking forms of the read and write members are defined, with the form chosen based on overload resolution.
The read and write member functions may be invoked within device code, or within a SYCL host program. Some interfaces may not be available on all devices/implementations, but the pipe definition itself does not gate availability. Instead, implementations should error if an unsupported pipe is used. See section <<device_queries>> for information on querying the availability of specific pipe features relative to a device.
194
194
195
195
The template parameters of the device type are defined as:
196
196
197
-
* `name`: Type that is the basis of pipe identification. Typically a user-defined class, in a user namespace. Forward declaration of the type is sufficient, and the type does not need to be defined.
198
-
* `dataT`: The type of data word/packet contained within a pipe. This is the data type that is read during a successful `pipe::read` operation, or written during a successful `pipe::write` operation. The type must be standard layout and trivially copyable. This template parameter can be queried by using the `value_type` type alias.
199
-
* `min_capacity`: User defined minimum number of words in units of `dataT` that the pipe must be able to store without any being read out. A minimum capacity is required in some algorithms to avoid deadlock, or for performance tuning. An implementation can include more capacity than this parameter, but not less. This template parameter can be queried by using the `min_capacity` static member.
197
+
* `_name`: Type that is the basis of pipe identification. Typically a user-defined class, in a user namespace. Forward declaration of the type is sufficient, and the type does not need to be defined.
198
+
* `_dataT`: The type of data word/packet contained within a pipe. This is the data type that is read during a successful `pipe::read` operation, or written during a successful `pipe::write` operation. The type must be standard layout and trivially copyable. This template parameter can be queried by using the `value_type` type alias.
199
+
* `_min_capacity`: User defined minimum number of words in units of `_dataT` that the pipe must be able to store without any being read out. A minimum capacity is required in some algorithms to avoid deadlock, or for performance tuning. An implementation can include more capacity than this parameter, but not less. This template parameter can be queried by using the `min_capacity` static member.
200
200
201
201
== Pipe types and {cpp} scope
202
202
@@ -260,12 +260,12 @@ Pipes expose two additional static member functions that are available within ho
0 commit comments