21 #include <system_error>
22 #include <type_traits>
25 inline namespace _V1 {
31 enum class errc : unsigned int {
64 std::string
message(
int)
const override {
return "SYCL Error"; }
75 class __SYCL_EXPORT
exception :
public virtual std::exception {
78 "no arguments is deprecated.")
89 exception(
int EV,
const std::error_category &ECat,
const std::string &WhatArg)
91 exception(
int,
const std::error_category &,
const char *);
92 exception(
int,
const std::error_category &);
106 const
std::error_category &category() const
noexcept;
108 const
char *what() const
noexcept final;
117 std::shared_ptr<detail::
string> MMsg;
135 const std::string &what_arg)
136 :
exception(Ec, SharedPtrCtx, what_arg.c_str()) {}
138 const char *WhatArg);
167 template <>
struct is_error_code_enum<
sycl::
errc> : true_type {};
The context class represents a SYCL context on which kernel functions may be executed.
std::string message(int) const override
const char * name() const noexcept override
exception(std::error_code Ec, const std::string &Msg, const int32_t URErr)
exception(std::error_code Ec, std::shared_ptr< context > SharedPtrCtx, const std::string &what_arg)
__SYCL2020_DEPRECATED("The version of an exception constructor which takes " "no arguments is deprecated.") exception()=default
exception(int EV, const std::error_category &ECat, const std::string &WhatArg)
Provides an abstraction of a SYCL kernel.
Defines the iteration domain of both the work-groups and the overall dispatch.
std::string codeToString(int32_t code)
const char * stringifyErrorCode(int32_t error)
int32_t get_ur_error(const exception &e)
exception set_ur_error(exception &&e, int32_t ur_err)
const std::error_category & sycl_category() noexcept
std::error_code make_error_code(sycl::errc E) noexcept
Constructs an error code using e and sycl_category()
_Abi const simd< _Tp, _Abi > & noexcept