From 94bdca6f1997a9c46a2b58eea187da132151d8ed Mon Sep 17 00:00:00 2001 From: Vukasin Milovanovic Date: Mon, 22 May 2023 17:38:26 -0700 Subject: [PATCH] Add log messages about kvikIO compatibility mode (#13363) Log whether kvikIO's compatibility mode is on for a given file input/output. Authors: - Vukasin Milovanovic (https://github.com/vuule) Approvers: - Nghia Truong (https://github.com/ttnghia) - Mike Wilson (https://github.com/hyperbolic2346) URL: https://github.com/rapidsai/cudf/pull/13363 --- cpp/src/io/utilities/data_sink.cpp | 2 ++ cpp/src/io/utilities/datasource.cpp | 2 ++ 2 files changed, 4 insertions(+) diff --git a/cpp/src/io/utilities/data_sink.cpp b/cpp/src/io/utilities/data_sink.cpp index 40b70986eca..f8d8702d1ca 100644 --- a/cpp/src/io/utilities/data_sink.cpp +++ b/cpp/src/io/utilities/data_sink.cpp @@ -38,6 +38,8 @@ class file_sink : public data_sink { if (detail::cufile_integration::is_kvikio_enabled()) { _kvikio_file = kvikio::FileHandle(filepath, "w"); + CUDF_LOG_INFO("Writing a file using kvikIO, with compatibility mode {}.", + _kvikio_file.is_compat_mode_on() ? "on" : "off"); } else { _cufile_out = detail::make_cufile_output(filepath); } diff --git a/cpp/src/io/utilities/datasource.cpp b/cpp/src/io/utilities/datasource.cpp index e2cea7a56ff..a457a803e3c 100644 --- a/cpp/src/io/utilities/datasource.cpp +++ b/cpp/src/io/utilities/datasource.cpp @@ -42,6 +42,8 @@ class file_source : public datasource { { if (detail::cufile_integration::is_kvikio_enabled()) { _kvikio_file = kvikio::FileHandle(filepath); + CUDF_LOG_INFO("Reading a file using kvikIO, with compatibility mode {}.", + _kvikio_file.is_compat_mode_on() ? "on" : "off"); } else { _cufile_in = detail::make_cufile_input(filepath); }