Skip to content

Commit

Permalink
Merge pull request #369 from masterleinad/document_kokkos_printf
Browse files Browse the repository at this point in the history
Add documentation for Kokkos::printf
  • Loading branch information
dalg24 authored Jul 10, 2023
2 parents 04f40b3 + c3126d0 commit c271f96
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 0 deletions.
1 change: 1 addition & 0 deletions docs/source/API/core/Utilities.rst
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ Utilities
./utilities/abort
./utilities/all
./utilities/complex
./utilities/printf
./utilities/timer
./utilities/device_id
./utilities/num_threads
Expand Down
16 changes: 16 additions & 0 deletions docs/source/API/core/printf.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
``Kokkos::printf``
=================

.. role:: cppkokkos(code)
:language: cppkokkos

Defined in header ``<Kokkos_Core.hpp>``

.. code-block:: cpp
template <typename... Args>
KOKKOS_FUNCTION void printf(const char* format, Args... args);
Prints the data specified in ``format`` and ``args...`` to ``stdout``.
The behavior is analogous to ``std::printf``, but the return type is ``void``
to ensure a consistent behavior across backends.

0 comments on commit c271f96

Please sign in to comment.