Lines Matching refs:handle
96 auto &handle = blashandles_[dctx->device->deviceId]; in initialize_handle_() local
99 if (!handle) { in initialize_handle_()
103 const auto cberr = cupmBlasCreate(handle.ptr_to()); in initialize_handle_()
115 PetscCallCUPMBLAS(cupmBlasSetStream(handle, dci->stream.get_stream())); in initialize_handle_()
116 dci->blas = handle; in initialize_handle_()
123 auto &handle = solverhandles_[dctx->device->deviceId]; in initialize_handle_() local
126 if (!handle) { in initialize_handle_()
130 const auto cerr = cupmSolverCreate(&handle); in initialize_handle_()
142 PetscCallCUPMSOLVER(cupmSolverSetStream(handle, dci->stream.get_stream())); in initialize_handle_()
143 dci->solver = handle; in initialize_handle_()
165 for (auto &&handle : blashandles_) { in finalize_()
166 if (handle) { in finalize_()
167 PetscCallCUPMBLAS(cupmBlasDestroy(handle)); in finalize_()
168 handle = nullptr; in finalize_()
171 for (auto &&handle : solverhandles_) { in finalize_()
172 if (handle) { in finalize_()
173 PetscCallCUPMSOLVER(cupmSolverDestroy(handle)); in finalize_()
174 handle = nullptr; in finalize_()
371 inline PetscErrorCode DeviceContext<T>::getHandle(PetscDeviceContext dctx, void *handle) noexcept in getHandle() argument
375 *static_cast<typename handle_t::type *>(handle) = impls_cast_(dctx)->get(handle_t{}); in getHandle()
381 inline PetscErrorCode DeviceContext<T>::getHandlePtr(PetscDeviceContext dctx, void **handle) noexce… in getHandlePtr() argument
387 …*reinterpret_cast<handle_type **>(handle) = const_cast<handle_type *>(std::addressof(impls_cast_(d… in getHandlePtr()