Skip to content

Commit

Permalink
Changed naming of pi_removed ifdef
Browse files Browse the repository at this point in the history
  • Loading branch information
konradkusiak97 committed Aug 19, 2024
1 parent 09fbb09 commit e902fcc
Show file tree
Hide file tree
Showing 12 changed files with 28 additions and 28 deletions.
4 changes: 2 additions & 2 deletions src/blas/backends/cublas/cublas_scope_handle.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ namespace cublas {
* takes place if no other element in the container has a key equivalent to
* the one being emplaced (keys in a map container are unique).
*/
#ifdef _PI_INTERFACE_REMOVED_
#ifdef ONEAPI_ONEMKL_PI_INTERFACE_REMOVED
thread_local cublas_handle<ur_context_handle_t> CublasScopedContextHandler::handle_helper =
cublas_handle<ur_context_handle_t>{};
#else
Expand Down Expand Up @@ -97,7 +97,7 @@ cublasHandle_t CublasScopedContextHandler::get_handle(const sycl::queue &queue)
CUresult cuErr;
CUcontext desired;
CUDA_ERROR_FUNC(cuDevicePrimaryCtxRetain, cuErr, &desired, cudaDevice);
#ifdef _PI_INTERFACE_REMOVED_
#ifdef ONEAPI_ONEMKL_PI_INTERFACE_REMOVED
auto piPlacedContext_ = reinterpret_cast<ur_context_handle_t>(desired);
#else
auto piPlacedContext_ = reinterpret_cast<pi_context>(desired);
Expand Down
6 changes: 3 additions & 3 deletions src/blas/backends/cublas/cublas_scope_handle.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,8 @@
// After Plugin Interface removal in DPC++ ur.hpp is the new include
#if __has_include(<sycl/detail/ur.hpp>)
#include <sycl/detail/ur.hpp>
#ifndef _PI_INTERFACE_REMOVED_
#define _PI_INTERFACE_REMOVED_
#ifndef ONEAPI_ONEMKL_PI_INTERFACE_REMOVED
#define ONEAPI_ONEMKL_PI_INTERFACE_REMOVED
#endif
#elif __has_include(<sycl/detail/pi.hpp>)
#include <sycl/detail/pi.hpp>
Expand Down Expand Up @@ -88,7 +88,7 @@ class CublasScopedContextHandler {
sycl::context *placedContext_;
bool needToRecover_;
sycl::interop_handle &ih;
#ifdef _PI_INTERFACE_REMOVED_
#ifdef ONEAPI_ONEMKL_PI_INTERFACE_REMOVED
static thread_local cublas_handle<ur_context_handle_t> handle_helper;
#else
static thread_local cublas_handle<pi_context> handle_helper;
Expand Down
4 changes: 2 additions & 2 deletions src/blas/backends/cublas/cublas_task.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,8 @@
// After Plugin Interface removal in DPC++ ur.hpp is the new include
#if __has_include(<sycl/detail/ur.hpp>)
#include <sycl/detail/ur.hpp>
#ifndef _PI_INTERFACE_REMOVED_
#define _PI_INTERFACE_REMOVED_
#ifndef ONEAPI_ONEMKL_PI_INTERFACE_REMOVED
#define ONEAPI_ONEMKL_PI_INTERFACE_REMOVED
#endif
#elif __has_include(<sycl/detail/pi.hpp>)
#include <sycl/detail/pi.hpp>
Expand Down
4 changes: 2 additions & 2 deletions src/blas/backends/rocblas/rocblas_scope_handle.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ rocblas_handle_container<T>::~rocblas_handle_container() noexcept(false) {
* takes place if no other element in the container has a key equivalent to
* the one being emplaced (keys in a map container are unique).
*/
#ifdef _PI_INTERFACE_REMOVED_
#ifdef ONEAPI_ONEMKL_PI_INTERFACE_REMOVED
thread_local rocblas_handle_container<ur_context_handle_t>
RocblasScopedContextHandler::handle_helper = rocblas_handle_container<ur_context_handle_t>{};
#else
Expand Down Expand Up @@ -113,7 +113,7 @@ rocblas_handle RocblasScopedContextHandler::get_handle(const sycl::queue &queue)
hipError_t hipErr;
hipCtx_t desired;
HIP_ERROR_FUNC(hipDevicePrimaryCtxRetain, hipErr, &desired, hipDevice);
#ifdef _PI_INTERFACE_REMOVED_
#ifdef ONEAPI_ONEMKL_PI_INTERFACE_REMOVED
auto piPlacedContext_ = reinterpret_cast<ur_context_handle_t>(desired);
#else
auto piPlacedContext_ = reinterpret_cast<pi_context>(desired);
Expand Down
6 changes: 3 additions & 3 deletions src/blas/backends/rocblas/rocblas_scope_handle.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@
// After Plugin Interface removal in DPC++ ur.hpp is the new include
#if __has_include(<sycl/detail/ur.hpp>)
#include <sycl/detail/ur.hpp>
#ifndef _PI_INTERFACE_REMOVED_
#define _PI_INTERFACE_REMOVED_
#ifndef ONEAPI_ONEMKL_PI_INTERFACE_REMOVED
#define ONEAPI_ONEMKL_PI_INTERFACE_REMOVED
#endif
#elif __has_include(<sycl/detail/pi.hpp>)
#include <sycl/detail/pi.hpp>
Expand All @@ -55,7 +55,7 @@ class RocblasScopedContextHandler {
sycl::context *placedContext_;
bool needToRecover_;
sycl::interop_handle &interop_h;
#ifdef _PI_INTERFACE_REMOVED_
#ifdef ONEAPI_ONEMKL_PI_INTERFACE_REMOVED
static thread_local rocblas_handle_container<ur_context_handle_t> handle_helper;
#else
static thread_local rocblas_handle_container<pi_context> handle_helper;
Expand Down
4 changes: 2 additions & 2 deletions src/blas/backends/rocblas/rocblas_task.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,8 @@
// After Plugin Interface removal in DPC++ ur.hpp is the new include
#if __has_include(<sycl/detail/ur.hpp>)
#include <sycl/detail/ur.hpp>
#ifndef _PI_INTERFACE_REMOVED_
#define _PI_INTERFACE_REMOVED_
#ifndef ONEAPI_ONEMKL_PI_INTERFACE_REMOVED
#define ONEAPI_ONEMKL_PI_INTERFACE_REMOVED
#endif
#elif __has_include(<sycl/detail/pi.hpp>)
#include <sycl/detail/pi.hpp>
Expand Down
4 changes: 2 additions & 2 deletions src/lapack/backends/cusolver/cusolver_scope_handle.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ namespace cusolver {
* takes place if no other element in the container has a key equivalent to
* the one being emplaced (keys in a map container are unique).
*/
#ifdef _PI_INTERFACE_REMOVED_
#ifdef ONEAPI_ONEMKL_PI_INTERFACE_REMOVED
thread_local cusolver_handle<ur_context_handle_t> CusolverScopedContextHandler::handle_helper =
cusolver_handle<ur_context_handle_t>{};
#else
Expand Down Expand Up @@ -98,7 +98,7 @@ cusolverDnHandle_t CusolverScopedContextHandler::get_handle(const sycl::queue &q
CUresult cuErr;
CUcontext desired;
CUDA_ERROR_FUNC(cuDevicePrimaryCtxRetain, cuErr, &desired, cudaDevice);
#ifdef _PI_INTERFACE_REMOVED_
#ifdef ONEAPI_ONEMKL_PI_INTERFACE_REMOVED
auto piPlacedContext_ = reinterpret_cast<ur_context_handle_t>(desired);
#else
auto piPlacedContext_ = reinterpret_cast<pi_context>(desired);
Expand Down
6 changes: 3 additions & 3 deletions src/lapack/backends/cusolver/cusolver_scope_handle.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,8 @@
// After Plugin Interface removal in DPC++ ur.hpp is the new include
#if __has_include(<sycl/detail/ur.hpp>)
#include <sycl/detail/ur.hpp>
#ifndef _PI_INTERFACE_REMOVED_
#define _PI_INTERFACE_REMOVED_
#ifndef ONEAPI_ONEMKL_PI_INTERFACE_REMOVED
#define ONEAPI_ONEMKL_PI_INTERFACE_REMOVED
#endif
#elif __has_include(<sycl/detail/pi.hpp>)
#include <sycl/detail/pi.hpp>
Expand Down Expand Up @@ -92,7 +92,7 @@ class CusolverScopedContextHandler {
sycl::context *placedContext_;
bool needToRecover_;
sycl::interop_handle &ih;
#ifdef _PI_INTERFACE_REMOVED_
#ifdef ONEAPI_ONEMKL_PI_INTERFACE_REMOVED
static thread_local cusolver_handle<ur_context_handle_t> handle_helper;
#else
static thread_local cusolver_handle<pi_context> handle_helper;
Expand Down
4 changes: 2 additions & 2 deletions src/lapack/backends/cusolver/cusolver_task.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,8 @@
// After Plugin Interface removal in DPC++ ur.hpp is the new include
#if __has_include(<sycl/detail/ur.hpp>)
#include <sycl/detail/ur.hpp>
#ifndef _PI_INTERFACE_REMOVED_
#define _PI_INTERFACE_REMOVED_
#ifndef ONEAPI_ONEMKL_PI_INTERFACE_REMOVED
#define ONEAPI_ONEMKL_PI_INTERFACE_REMOVED
#endif
#elif __has_include(<sycl/detail/pi.hpp>)
#include <sycl/detail/pi.hpp>
Expand Down
4 changes: 2 additions & 2 deletions src/lapack/backends/rocsolver/rocsolver_scope_handle.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ namespace rocsolver {
* takes place if no other element in the container has a key equivalent to
* the one being emplaced (keys in a map container are unique).
*/
#ifdef _PI_INTERFACE_REMOVED_
#ifdef ONEAPI_ONEMKL_PI_INTERFACE_REMOVED
thread_local rocsolver_handle<ur_context_handle_t> RocsolverScopedContextHandler::handle_helper =
rocsolver_handle<ur_context_handle_t>{};
#else
Expand Down Expand Up @@ -100,7 +100,7 @@ rocblas_handle RocsolverScopedContextHandler::get_handle(const sycl::queue &queu
hipError_t hipErr;
hipCtx_t desired;
HIP_ERROR_FUNC(hipDevicePrimaryCtxRetain, hipErr, &desired, hipDevice);
#ifdef _PI_INTERFACE_REMOVED_
#ifdef ONEAPI_ONEMKL_PI_INTERFACE_REMOVED
auto piPlacedContext_ = reinterpret_cast<ur_context_handle_t>(desired);
#else
auto piPlacedContext_ = reinterpret_cast<pi_context>(desired);
Expand Down
6 changes: 3 additions & 3 deletions src/lapack/backends/rocsolver/rocsolver_scope_handle.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,8 @@
// After Plugin Interface removal in DPC++ ur.hpp is the new include
#if __has_include(<sycl/detail/ur.hpp>)
#include <sycl/detail/ur.hpp>
#ifndef _PI_INTERFACE_REMOVED_
#define _PI_INTERFACE_REMOVED_
#ifndef ONEAPI_ONEMKL_PI_INTERFACE_REMOVED
#define ONEAPI_ONEMKL_PI_INTERFACE_REMOVED
#endif
#elif __has_include(<sycl/detail/pi.hpp>)
#include <sycl/detail/pi.hpp>
Expand All @@ -55,7 +55,7 @@ class RocsolverScopedContextHandler {
sycl::context *placedContext_;
bool needToRecover_;
sycl::interop_handle &ih;
#ifdef _PI_INTERFACE_REMOVED_
#ifdef ONEAPI_ONEMKL_PI_INTERFACE_REMOVED
static thread_local rocsolver_handle<ur_context_handle_t> handle_helper;
#else
static thread_local rocsolver_handle<pi_context> handle_helper;
Expand Down
4 changes: 2 additions & 2 deletions src/lapack/backends/rocsolver/rocsolver_task.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,8 @@
// After Plugin Interface removal in DPC++ ur.hpp is the new include
#if __has_include(<sycl/detail/ur.hpp>)
#include <sycl/detail/ur.hpp>
#ifndef _PI_INTERFACE_REMOVED_
#define _PI_INTERFACE_REMOVED_
#ifndef ONEAPI_ONEMKL_PI_INTERFACE_REMOVED
#define ONEAPI_ONEMKL_PI_INTERFACE_REMOVED
#endif
#elif __has_include(<sycl/detail/pi.hpp>)
#include <sycl/detail/pi.hpp>
Expand Down

0 comments on commit e902fcc

Please sign in to comment.