15 #include <type_traits>
18 inline namespace _V1 {
19 namespace ext::intel::experimental {
40 return static_cast<fp_mode>(
static_cast<std::underlying_type_t<fp_mode>
>(
a) |
41 static_cast<std::underlying_type_t<fp_mode>
>(
b));
46 return static_cast<fp_mode>(
static_cast<std::underlying_type_t<fp_mode>
>(
a) &
47 static_cast<std::underlying_type_t<fp_mode>
>(
b));
50 return static_cast<fp_mode>(
static_cast<std::underlying_type_t<fp_mode>
>(
a) ^
51 static_cast<std::underlying_type_t<fp_mode>
>(
b));
54 return (
mode & flag) == flag;
60 bool isCorrectRoundingMode = ((
mode & roundMask) ==
fp_mode(0)) ||
70 return isCorrectRoundingMode && isCorrectDenormMode;
90 oneapi::experimental::detail::PropKind::FloatingPointControls> {
91 template <fp_mode option>
96 template <fp_mode option>
101 namespace ext::oneapi::experimental {
102 template <
typename T,
typename PropertyListT>
104 intel::experimental::fp_control_key,
109 template <
intel::experimental::fp_mode FPMode>
112 "Mutually exclusive fp modes are specified for the kernel.");
113 static constexpr
const char *
name =
"sycl-floating-point-control";
constexpr fp_mode setDefaultValuesIfNeeded(fp_mode mode)
constexpr fp_mode operator^(const fp_mode &a, const fp_mode &b)
constexpr bool isSet(const fp_mode &mode, const fp_mode &flag)
constexpr bool checkMutuallyExclusive(const fp_mode &mode)
constexpr fp_mode operator&(const fp_mode &a, const fp_mode &b)
constexpr fp_control_key::value_t< option > fp_control
constexpr fp_mode operator|(const fp_mode &a, const fp_mode &b)