Skip to content

Commit

Permalink
[SYCL][Graph] Makes command graph functions thread-safe
Browse files Browse the repository at this point in the history
Adds comments
  • Loading branch information
mfrancepillois committed Aug 4, 2023
1 parent 5a15113 commit 079a042
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions sycl/source/detail/graph_impl.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -772,6 +772,10 @@ class exec_graph_impl {
std::list<std::shared_ptr<node_impl>> MSchedule;
/// Pointer to the modifiable graph impl associated with this executable
/// graph.
/// Thread-safe implementation note: in the current implementation
/// multiple exec_graph_impl can reference the same graph_impl object.
/// This specificity must be taken into account when trying to lock
/// the graph_impl mutex from an exec_graph_impl to avoid deadlock.
std::shared_ptr<graph_impl> MGraphImpl;
/// Map of devices to command buffers.
std::unordered_map<sycl::device, sycl::detail::pi::PiExtCommandBuffer>
Expand Down

0 comments on commit 079a042

Please sign in to comment.