DPC++ Runtime
Runtime libraries for oneAPI DPC++
fusion_wrapper.hpp
Go to the documentation of this file.
1 //==---- fusion_wrapper.hpp --- SYCL wrapper for queue for kernel fusion ---==//
2 //
3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4 // See https://llvm.org/LICENSE.txt for license information.
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6 //
7 //===----------------------------------------------------------------------===//
8 
9 #pragma once
10 
11 #include <sycl/queue.hpp>
12 
13 namespace sycl {
15 
16 namespace detail {
17 class fusion_wrapper_impl;
18 }
19 
20 namespace ext::codeplay::experimental {
21 
25 class __SYCL_EXPORT fusion_wrapper {
26 
27 public:
33  explicit fusion_wrapper(queue &q);
34 
37  queue get_queue() const;
38 
41  bool is_in_fusion_mode() const;
42 
51  void start_fusion();
52 
67  void cancel_fusion();
68 
87  event complete_fusion(const property_list &propList = {});
88 
89 private:
90  std::shared_ptr<detail::fusion_wrapper_impl> MImpl;
91 };
92 } // namespace ext::codeplay::experimental
93 } // __SYCL_INLINE_VER_NAMESPACE(_V1)
94 } // namespace sycl
sycl::_V1::property_list
Objects of the property_list class are containers for the SYCL properties.
Definition: property_list.hpp:24
__SYCL_INLINE_VER_NAMESPACE
#define __SYCL_INLINE_VER_NAMESPACE(X)
Definition: defines_elementary.hpp:11
sycl
---— Error handling, matching OpenCL plugin semantics.
Definition: access.hpp:14
sycl::_V1::ext::codeplay::experimental::fusion_wrapper
A wrapper wrapping a sycl::queue to provide access to the kernel fusion API, allowing to manage kerne...
Definition: fusion_wrapper.hpp:25
sycl::_V1::queue
Encapsulates a single SYCL queue which schedules kernels on a SYCL device.
Definition: queue.hpp:89
queue.hpp