diff --git a/common/cuda_hip/log/batch_logger.hpp.inc b/common/cuda_hip/log/batch_logger.hpp similarity index 71% rename from common/cuda_hip/log/batch_logger.hpp.inc rename to common/cuda_hip/log/batch_logger.hpp index 04b614b50f9..5e897b3c67d 100644 --- a/common/cuda_hip/log/batch_logger.hpp.inc +++ b/common/cuda_hip/log/batch_logger.hpp @@ -2,6 +2,18 @@ // // SPDX-License-Identifier: BSD-3-Clause +#ifndef GKO_COMMON_CUDA_HIP_LOG_BATCH_LOGGER_HPP_ +#define GKO_COMMON_CUDA_HIP_LOG_BATCH_LOGGER_HPP_ + + +#include + + +namespace gko { +namespace kernels { +namespace GKO_DEVICE_NAMESPACE { +namespace batch_log { + /** * @see reference/log/batch_logger.hpp */ @@ -28,3 +40,12 @@ class SimpleFinalLogger final { real_type* const final_residuals_; idx_type* const final_iters_; }; + + +} // namespace batch_log +} // namespace GKO_DEVICE_NAMESPACE +} // namespace kernels +} // namespace gko + + +#endif diff --git a/core/solver/batch_dispatch.hpp b/core/solver/batch_dispatch.hpp index 178f6b1beae..018a6674df5 100644 --- a/core/solver/batch_dispatch.hpp +++ b/core/solver/batch_dispatch.hpp @@ -25,10 +25,10 @@ #include "common/cuda_hip/base/batch_struct.hpp" +#include "common/cuda_hip/log/batch_logger.hpp" #include "common/cuda_hip/matrix/batch_struct.hpp" #include "common/cuda_hip/preconditioner/batch_preconditioners.hpp" -#include "cuda/log/batch_logger.cuh" -#include "cuda/stop/batch_criteria.cuh" +#include "common/cuda_hip/stop/batch_criteria.hpp" namespace gko { @@ -52,10 +52,10 @@ using DeviceValueType = typename gko::kernels::cuda::cuda_type; #include "common/cuda_hip/base/batch_struct.hpp" +#include "common/cuda_hip/log/batch_logger.hpp" #include "common/cuda_hip/matrix/batch_struct.hpp" #include "common/cuda_hip/preconditioner/batch_preconditioners.hpp" -#include "hip/log/batch_logger.hip.hpp" -#include "hip/stop/batch_criteria.hip.hpp" +#include "common/cuda_hip/stop/batch_criteria.hpp" namespace gko { diff --git a/cuda/log/batch_logger.cuh b/cuda/log/batch_logger.cuh deleted file mode 100644 index 3e53d6ef0a6..00000000000 --- a/cuda/log/batch_logger.cuh +++ /dev/null @@ -1,27 +0,0 @@ -// SPDX-FileCopyrightText: 2017 - 2024 The Ginkgo authors -// -// SPDX-License-Identifier: BSD-3-Clause - -#ifndef GKO_CUDA_LOG_BATCH_LOGGER_CUH_ -#define GKO_CUDA_LOG_BATCH_LOGGER_CUH_ - - -#include - - -namespace gko { -namespace kernels { -namespace cuda { -namespace batch_log { - - -#include "common/cuda_hip/log/batch_logger.hpp.inc" - - -} // namespace batch_log -} // namespace cuda -} // namespace kernels -} // namespace gko - - -#endif // GKO_CUDA_LOG_BATCH_LOGGER_CUH_ diff --git a/hip/log/batch_logger.hip.hpp b/hip/log/batch_logger.hip.hpp deleted file mode 100644 index a2540f2bd9d..00000000000 --- a/hip/log/batch_logger.hip.hpp +++ /dev/null @@ -1,26 +0,0 @@ -// SPDX-FileCopyrightText: 2017 - 2024 The Ginkgo authors -// -// SPDX-License-Identifier: BSD-3-Clause - -#ifndef GKO_HIP_LOG_BATCH_LOGGER_HIP_HPP_ -#define GKO_HIP_LOG_BATCH_LOGGER_HIP_HPP_ - - -#include - - -namespace gko { -namespace kernels { -namespace hip { -namespace batch_log { - -#include "common/cuda_hip/log/batch_logger.hpp.inc" - - -} // namespace batch_log -} // namespace hip -} // namespace kernels -} // namespace gko - - -#endif // GKO_HIP_LOG_BATCH_LOGGER_HIP_HPP_