Classes | Enumerations | Functions
defaults.hpp File Reference
#include <algorithm>
#include <cstddef>
#include <cstdlib>
#include <sstream>
#include <stdexcept>
#include <string>
#include <BS_thread_pool.hpp>
#include <kvikio/shim/cufile.hpp>

Go to the source code of this file.

Classes

class  kvikio::defaults
 Singleton class of default values used throughout KvikIO. More...
 

Enumerations

enum class  kvikio::CompatMode : uint8_t { OFF , ON , AUTO }
 I/O compatibility mode. More...
 

Functions

CompatMode kvikio::detail::parse_compat_mode_str (std::string_view compat_mode_str)
 Parse a string into a CompatMode enum. More...
 
template<typename T >
kvikio::detail::getenv_or (std::string_view env_var_name, T default_val)
 
template<>
bool kvikio::detail::getenv_or (std::string_view env_var_name, bool default_val)
 
template<>
CompatMode kvikio::detail::getenv_or (std::string_view env_var_name, CompatMode default_val)
 

Enumeration Type Documentation

◆ CompatMode

enum kvikio::CompatMode : uint8_t
strong

I/O compatibility mode.

Enumerator
OFF 

Enforce cuFile I/O. GDS will be activated if the system requirements for cuFile are met and cuFile is properly configured. However, if the system is not suited for cuFile, I/O operations under the OFF option may error out, crash or hang.

ON 

Enforce POSIX I/O.

AUTO 

Try cuFile I/O first, and fall back to POSIX I/O if the system requirements for cuFile are not met.

Definition at line 38 of file defaults.hpp.

Function Documentation

◆ parse_compat_mode_str()

CompatMode kvikio::detail::parse_compat_mode_str ( std::string_view  compat_mode_str)
inline

Parse a string into a CompatMode enum.

Parameters
compat_mode_strCompatibility mode in string format(case-insensitive). Valid values include:
  • ON (alias: TRUE, YES, 1)
  • OFF (alias: FALSE, NO, 0)
  • AUTO
Returns
A CompatMode enum.

Definition at line 58 of file defaults.hpp.