| 72 | } |
| 73 | |
| 74 | kernel::kernel(const char* image, const std::string& name) : impl(std::make_shared<kernel_impl>()) |
| 75 | { |
| 76 | impl->module = load_module(image); |
| 77 | auto status = hipModuleGetFunction(&impl->fun, impl->module.get(), name.c_str()); |
| 78 | if(hipSuccess != status) |
| 79 | MIGRAPHX_THROW("Failed to get function: " + name + ": " + hip_error(status)); |
| 80 | } |
| 81 | |
| 82 | bool kernel::empty() const { return impl == nullptr; } |
| 83 |
nothing calls this directly
no test coverage detected