Standard API

Standard Library Backports

C++ Standard versions include new language features and new library features. As the name implies, language features are new features of the language the require compiler support. Library features are simply new additions to the Standard Library that typically do not rely on new language features nor require compiler support and could conceivably be implemented in an older C++ Standard.

Typically, library features are only available in the particular C++ Standard version (or newer) in which they were introduced, even if the library features do not depend on any particular language features.

In effort to make library features available to a broader set of users, the NVIDIA C++ Standard Library relaxes this restriction. libcu++ makes a best-effort to provide access to C++ Standard Library features in older C++ Standard versions than they were introduced. For example, the calendar functionality added to <chrono> in C++20 is made available in C++14.


C++ Feature Availability Summary

Library

Libcu++

≤ C++17

C++20

C++23

C++26

Notes

<array>

<cuda/std/array>

<atomic>

<cuda/std/atomic>

<barrier>

<cuda/std/barrier>

<bit>

<cuda/std/bit>

<bitset>

<cuda/std/bitset>

<chrono>

<cuda/std/chrono>

Timezone and clocks added in C++20 are not available

<complex>

<cuda/std/complex>

constexpr if is_constant_evaluated is supported

<concepts>

<cuda/std/concepts>

<expected>

<cuda/std/expected>

<functional>

<cuda/std/functional>

<initializer_list>

<cuda/std/initializer_list>

<inplace_vector>

<cuda/std/inplace_vector>

<iterator>

<cuda/std/iterator>

<latch>

<cuda/std/latch>

<limits>

<cuda/std/limits>

<linalg>

<cuda/std/linalg>

Accessors, transposed layout, and related functions

<mdspan>

<cuda/std/mdspan>

<memory>

<cuda/std/memory>

cuda::std::addressof, cuda::std::align, cuda::std::assume_aligned, Uninitialized memory algorithms

<numbers>

<cuda/std/numbers>

<numeric>

<cuda/std/numeric>

<optional>

<cuda/std/optional>

<ranges>

<cuda/std/ranges>

Requires C++20, Range based algorithms and views are not provided

<ratio>

<cuda/std/ratio>

<semaphore>

<cuda/std/semaphore>

<source_location>

<cuda/std/source_location>

<span>

<cuda/std/span>

<tuple>

<cuda/std/tuple>

<type_traits>

<cuda/std/type_traits>

<utility>

<cuda/std/utility>

<variant>

<cuda/std/variant>

<version>

<cuda/std/version>


C Feature Availability Summary

Library

Libcu++

≤ C++17

<cassert>

<cuda/std/cassert>

<ccomplex>

<cuda/std/ccomplex>

<cfloat>

<cuda/std/cfloat>

<climits>

<cuda/std/climits>

<cmath>

<cuda/std/cmath>

<cstddef>

<cuda/std/cstddef>

<cstdint>

<cuda/std/cstdint>

<cstdlib>

<cuda/std/cstdlib>

<cstring>

<cuda/std/cstring>

<ctime>

<cuda/std/ctime>

see C Libraries for more details