DPC++ Runtime
Runtime libraries for oneAPI DPC++
properties.hpp
Go to the documentation of this file.
1 //==--- properties.hpp - SYCL properties associated with latency_control ---==//
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 
13 
15 namespace sycl::ext {
16 namespace intel::experimental {
17 
19  none, // default
20  exact,
21  max,
22  min
23 };
24 
26  template <int Anchor>
27  using value_t =
29  std::integral_constant<int, Anchor>>;
30 };
31 
33  template <int Target, latency_control_type Type, int Cycle>
35  latency_constraint_key, std::integral_constant<int, Target>,
36  std::integral_constant<latency_control_type, Type>,
37  std::integral_constant<int, Cycle>>;
38 };
39 
40 template <int Anchor>
42 template <int Target, latency_control_type Type, int Cycle>
45 
46 } // namespace intel::experimental
47 
48 namespace oneapi::experimental {
49 
50 template <int Target, intel::experimental::latency_control_type Type, int Cycle>
52  intel::experimental::latency_constraint_key,
53  std::integral_constant<int, Target>,
54  std::integral_constant<intel::experimental::latency_control_type, Type>,
55  std::integral_constant<int, Cycle>> {
57  static constexpr int target = Target;
58  static constexpr intel::experimental::latency_control_type type = Type;
59  static constexpr int cycle = Cycle;
60 };
61 
62 template <>
63 struct is_property_key<intel::experimental::latency_anchor_id_key>
64  : std::true_type {};
65 template <>
66 struct is_property_key<intel::experimental::latency_constraint_key>
67  : std::true_type {};
68 
69 namespace detail {
70 
71 template <> struct PropertyToKind<intel::experimental::latency_anchor_id_key> {
72  static constexpr PropKind Kind = PropKind::LatencyAnchorID;
73 };
74 template <> struct PropertyToKind<intel::experimental::latency_constraint_key> {
75  static constexpr PropKind Kind = PropKind::LatencyConstraint;
76 };
77 
78 template <>
79 struct IsCompileTimeProperty<intel::experimental::latency_anchor_id_key>
80  : std::true_type {};
81 template <>
82 struct IsCompileTimeProperty<intel::experimental::latency_constraint_key>
83  : std::true_type {};
84 
85 } // namespace detail
86 } // namespace oneapi::experimental
87 } // namespace sycl::ext
88 } // __SYCL_INLINE_NAMESPACE(cl)
cl::sycl::ext::oneapi::experimental::detail::PropKind
PropKind
Definition: property.hpp:165
cl::sycl::ext::oneapi::experimental::is_property_key
Definition: property.hpp:201
cl::sycl::ext::intel::experimental::latency_anchor_id_key
Definition: properties.hpp:25
cl::sycl::ext::intel::experimental::latency_control_type::exact
@ exact
cl::sycl::ext::intel::experimental::latency_constraint_key
Definition: properties.hpp:32
cl::sycl::ext::oneapi::experimental::detail::IsCompileTimeProperty
Definition: property.hpp:189
max
simd< _Tp, _Abi > max(const simd< _Tp, _Abi > &, const simd< _Tp, _Abi > &) noexcept
sycl::ext
Definition: invoke_simd.hpp:69
cl::sycl::ext::oneapi::experimental::detail::LatencyAnchorID
@ LatencyAnchorID
Definition: property.hpp:170
cl::sycl::ext::oneapi::experimental::detail::PropertyToKind
Definition: property.hpp:177
property_value.hpp
cl::sycl::access::target
target
Definition: access.hpp:17
cl
We provide new interfaces for matrix muliply in this patch:
Definition: access.hpp:13
cl::sycl::ext::intel::experimental::latency_constraint
constexpr latency_constraint_key::value_t< Target, Type, Cycle > latency_constraint
Definition: properties.hpp:44
cl::sycl::ext::intel::experimental::latency_control_type
latency_control_type
Definition: properties.hpp:18
cl::sycl::ext::intel::experimental::latency_anchor_id
constexpr latency_anchor_id_key::value_t< Anchor > latency_anchor_id
Definition: properties.hpp:41
property.hpp
cl::sycl::ext::oneapi::experimental::property_value
Definition: property_utils.hpp:23
cl::sycl::ext::oneapi::experimental::detail::LatencyConstraint
@ LatencyConstraint
Definition: property.hpp:171
min
simd< _Tp, _Abi > min(const simd< _Tp, _Abi > &, const simd< _Tp, _Abi > &) noexcept
__SYCL_INLINE_NAMESPACE
#define __SYCL_INLINE_NAMESPACE(X)
Definition: defines_elementary.hpp:11