/home/docs/checkouts/readthedocs.org/user_builds/advanced-micro-devices-composable-kernel/checkouts/develop/include/ck_tile/host/hip_check_error.hpp File Reference#
hip_check_error.hpp File Reference
#include "ck_tile/core/config.hpp"
#include <sstream>
#include <stdexcept>
#include <hip/hip_runtime.h>
Go to the source code of this file.
Namespaces | |
ck_tile | |
Macros | |
#define | HIP_CHECK_ERROR(retval_or_funcall) |
Functions | |
CK_TILE_HOST void | ck_tile::hip_check_error (hipError_t x) |
Macro Definition Documentation
◆ HIP_CHECK_ERROR
#define HIP_CHECK_ERROR | ( | retval_or_funcall | ) |
Value:
do \
{ \
hipError_t _tmpVal = retval_or_funcall; \
if(_tmpVal != hipSuccess) \
{ \
std::ostringstream ostr; \
ostr << "HIP Function Failed (" << __FILE__ << "," << __LINE__ << ") " \
<< hipGetErrorString(_tmpVal); \
throw std::runtime_error(ostr.str()); \
} \
} while(0)