diff --git a/sycl/doc/extensions/experimental/sycl_ext_oneapi_graph.asciidoc b/sycl/doc/extensions/experimental/sycl_ext_oneapi_graph.asciidoc index 283ae72abd6ff..9f535f38d2c94 100644 --- a/sycl/doc/extensions/experimental/sycl_ext_oneapi_graph.asciidoc +++ b/sycl/doc/extensions/experimental/sycl_ext_oneapi_graph.asciidoc @@ -271,8 +271,8 @@ represents either a command-group or an empty operation. through newly added interfaces. This is either using the `make_edge()` function to define an edge between existing nodes, or using a `property::node::depends_on` property list when adding a new node to the graph. -Nodes passed to this property that are from the same graph will create edges -within the graph. +Nodes or <> passed to this property +that are from the same graph will create edges within the graph. Edges can also be created when explicitly adding nodes to the graph through existing SYCL mechanisms for expressing dependencies. Data dependencies from @@ -281,8 +281,8 @@ accessors to existing nodes in the graph are captured as an edge. Using `handler::depends_on()` inside the node's command-group function can also be used for defining graph edges. However, for an event passed to `handler::depends_on()` to create an edge, it must be an event returned from a -queue submission captured by a graph (a <>). +queue submission captured by the same graph (a <>). | External Dependencies | Graph nodes may have dependencies on operations outside of the graph they belong to. These can be dependencies on nodes from @@ -298,8 +298,8 @@ respected when the graph is executed. ===== Explicit API Example Simple example that shows using the explicit API to add two nodes to a graph -with the <> used to define -dependencies between them. +with the <> used to define the +graph edge between them. [source, c++] ---- @@ -369,7 +369,7 @@ graph nodes that will be respected when the graph is executed. ===== Queue Recording API Example Simple example that shows using the Queue Recording API to add two nodes to a -graph with a `sycl::event` used to define the dependency between them. +graph with a `sycl::event` used to define the graph edge between them. [source, c++] ---- @@ -392,6 +392,8 @@ SyclQueue.submit( } ); +Graph.end_recording(); + sycl_ext::command_graph ExecGraph = Graph.finalize(); SyclQueue.ext_oneapi_graph(ExecGraph); @@ -692,13 +694,14 @@ be passed here. `depends_on` may be used in two ways: * Passing nodes from the same `command_graph` which will create dependencies and graph edges between those nodes and the node being added. -* Passing SYCL events, including <>. If an event -is a <>, then a graph edge is created -between this node and the other node. For dynamic events, or -<>, an external dependency is created -between this node and the command that is associated with the event. Passing a -default constructed `dynamic_event` with no associated SYCL event will result in -a synchronous error being thrown. +* Passing SYCL events, including <>. If an event +is a <> from the same `command_graph`, +then a graph edge is created between this node and the other node. For dynamic +events, graph-limited events from a different graph or <>, an external dependency is created between this node and +the command that is associated with the event. Passing a default constructed +`dynamic_event` with no associated SYCL event will result in a synchronous error +being thrown. The only permitted types for `NodeTN` and `EventTN` are `node` and `event`/`dynamic_event` respectively.