Skip to content

Commit

Permalink
[DFT] Constrain data_type in compute_*ward real-real inplace (#544)
Browse files Browse the repository at this point in the history
* [DFT] Constrain data_type in compute_*ward real-real inplace

* The compute_*ward real-real implace overload can be selected when the user
intends to use the complex-complex out-of-place overload.
* This suggestion stops this from happening when the user uses non-float
arguments that are presumably intended for the complex-complex overload.

* Use consistent wording; Align changes to 80 column limit

* Missing data_desc; Source formating #2
  • Loading branch information
hjabird authored Jul 2, 2024
1 parent d8121f0 commit 2c09ad3
Show file tree
Hide file tree
Showing 2 changed files with 57 additions and 27 deletions.
40 changes: 27 additions & 13 deletions source/elements/oneMKL/source/domains/dft/compute_backward.rst
Original file line number Diff line number Diff line change
Expand Up @@ -108,13 +108,15 @@ compute_backward (Buffer version)
inout_re
``sycl::buffer`` object of sufficient capacity to store the elements
defining the real parts of all the relevant data sequences, as configured
by ``desc``. Only with complex descriptors configured for in-place operations with
by ``desc``. ``data_type`` must be single or double precision floating-point, as
described by the descriptor's precision. Only with complex descriptors configured for in-place operations with
:ref:`onemkl_dft_complex_storage_real_real`.

inout_im
``sycl::buffer`` object of sufficient capacity to store the elements
defining the imaginary parts of all the relevant data sequences, as
configured by ``desc``. Only with complex descriptors configured for in-place
configured by ``desc``. ``data_type`` must be single or double precision floating-point, as
described by the descriptor's precision. Only with complex descriptors configured for in-place
operations with :ref:`onemkl_dft_complex_storage_real_real`.

in
Expand Down Expand Up @@ -149,14 +151,18 @@ compute_backward (Buffer version)
inout_re
``sycl::buffer`` object of sufficient capacity to store the elements
defining the real parts of all the relevant data sequences, as configured
by ``desc``. Only with complex descriptors configured for in-place operations with
by ``desc``. ``data_type`` must be single or double precision
floating-point, as described by the descriptor's precision. Only with
complex descriptors configured for in-place operations with
:ref:`onemkl_dft_complex_storage_real_real`.

inout_im
``sycl::buffer`` object of sufficient capacity to store the elements
defining the imaginary parts of all the relevant data sequences, as
configured by ``desc``. Only with complex descriptors configured for in-place
operations with :ref:`onemkl_dft_complex_storage_real_real`.
configured by ``desc``. ``data_type`` must be single or double precision
floating-point, as described by the descriptor's precision. Only with
complex descriptors configured for in-place operations with
:ref:`onemkl_dft_complex_storage_real_real`.

out
``sycl::buffer`` object of sufficient capacity to store the elements
Expand Down Expand Up @@ -267,14 +273,18 @@ compute_backward (USM version)
inout_re
Pointer to USM allocation of sufficient capacity to store the elements
defining the real parts of all the relevant data sequences, as configured
by ``desc``. Only with complex descriptors configured for in-place operations with
by ``desc``. ``data_type`` must be single or double precision
floating-point, as described by the descriptor's precision. Only with
complex descriptors configured for in-place operations with
:ref:`onemkl_dft_complex_storage_real_real`.

inout_im
Pointer to USM allocation of sufficient capacity to store the elements
defining the imaginary parts of all the relevant data sequences, as
configured by ``desc``. Only with complex descriptors configured for in-place
operations with :ref:`onemkl_dft_complex_storage_real_real`.
configured by ``desc``. ``data_type`` must be single or double precision
floating-point, as described by the descriptor's precision. Only with
complex descriptors configured for in-place operations with
:ref:`onemkl_dft_complex_storage_real_real`.

in
Pointer to USM allocation of sufficient capacity to store the elements
Expand Down Expand Up @@ -311,15 +321,19 @@ compute_backward (USM version)

inout_re
Pointer to USM allocation of sufficient capacity to store the elements
defining the real parts of all the relevant data sequences, as
configured by ``desc``. Only with complex descriptors configured for in-place
operations with :ref:`onemkl_dft_complex_storage_real_real`.
defining the real parts of all the relevant data sequences, as configured
by ``desc``. ``data_type`` must be single or double precision
floating-point, as described by the descriptor's precision. Only with
complex descriptors configured for in-place operations with
:ref:`onemkl_dft_complex_storage_real_real`.

inout_im
Pointer to USM allocation of sufficient capacity to store the elements
defining the imaginary parts of all the relevant data sequences, as
configured by ``desc``. Only with complex descriptors configured for in-place
operations with :ref:`onemkl_dft_complex_storage_real_real`.
configured by ``desc``. ``data_type`` must be single or double precision
floating-point, as described by the descriptor's precision. Only with
complex descriptors configured for in-place operations with
:ref:`onemkl_dft_complex_storage_real_real`.

out
Pointer to USM allocation of sufficient capacity to store the elements
Expand Down
44 changes: 30 additions & 14 deletions source/elements/oneMKL/source/domains/dft/compute_forward.rst
Original file line number Diff line number Diff line change
Expand Up @@ -107,15 +107,19 @@ compute_forward (Buffer version)

inout_re
``sycl::buffer`` object of sufficient capacity to store the elements
defining the real parts of all the relevant data sequences, as
configured by ``desc``. Only with complex descriptors configured for in-place
operations with :ref:`onemkl_dft_complex_storage_real_real`.
defining the real parts of all the relevant data sequences, as configured
by ``desc``. ``data_type`` must be single or double precision
floating-point, as described by the descriptor's precision. Only with
complex descriptors configured for in-place operations with
:ref:`onemkl_dft_complex_storage_real_real`.

inout_im
``sycl::buffer`` object of sufficient capacity to store the elements
defining the imaginary parts of all the relevant data sequences, as
configured by ``desc``. Only with complex descriptors configured for in-place
operations with :ref:`onemkl_dft_complex_storage_real_real`.
configured by ``desc``. ``data_type`` must be single or double precision
floating-point, as described by the descriptor's precision. Only with
complex descriptors configured for in-place operations with
:ref:`onemkl_dft_complex_storage_real_real`.

in
``sycl::buffer`` object of sufficient capacity to store the elements
Expand Down Expand Up @@ -149,14 +153,18 @@ compute_forward (Buffer version)
inout_re
``sycl::buffer`` object of sufficient capacity to store the elements
defining the real parts of all the relevant data sequences, as configured
by ``desc``. Only with complex descriptors configured for in-place operations with
by ``desc``. ``data_type`` must be single or double precision
floating-point, as described by the descriptor's precision. Only with
complex descriptors configured for in-place operations with
:ref:`onemkl_dft_complex_storage_real_real`.

inout_im
``sycl::buffer`` object of sufficient capacity to store the elements
defining the imaginary parts of all the relevant data sequences, as
configured by ``desc``. Only with complex descriptors configured for in-place
operations with :ref:`onemkl_dft_complex_storage_real_real`.
configured by ``desc``. ``data_type`` must be single or double precision
floating-point, as described by the descriptor's precision. Only with
complex descriptors configured for in-place operations with
:ref:`onemkl_dft_complex_storage_real_real`.

out
``sycl::buffer`` object of sufficient capacity to store the elements
Expand Down Expand Up @@ -267,14 +275,18 @@ compute_forward (USM version)
inout_re
Pointer to USM allocation of sufficient capacity to store the elements
defining the real parts of all the relevant data sequences, as configured
by ``desc``. Only with complex descriptors configured for in-place operations with
by ``desc``. ``data_type`` must be single or double precision
floating-point, as described by the descriptor's precision. Only with
complex descriptors configured for in-place operations with
:ref:`onemkl_dft_complex_storage_real_real`.

inout_im
Pointer to USM allocation of sufficient capacity to store the elements
defining the imaginary parts of all the relevant data sequences, as
configured by ``desc``. Only with complex descriptors configured for in-place
operations with :ref:`onemkl_dft_complex_storage_real_real`.
configured by ``desc``. ``data_type`` must be single or double precision
floating-point, as described by the descriptor's precision. Only with
complex descriptors configured for in-place operations with
:ref:`onemkl_dft_complex_storage_real_real`.

in
Pointer to USM allocation of sufficient capacity to store the elements
Expand Down Expand Up @@ -312,14 +324,18 @@ compute_forward (USM version)
inout_re
Pointer to USM allocation of sufficient capacity to store the elements
defining the real parts of all the relevant data sequences, as configured
by ``desc``. Only with complex descriptors configured for in-place operations with
by ``desc``. ``data_type`` must be single or double precision
floating-point, as described by the descriptor's precision. Only with
complex descriptors configured for in-place operations with
:ref:`onemkl_dft_complex_storage_real_real`.

inout_im
Pointer to USM allocation of sufficient capacity to store the elements
defining the imaginary parts of all the relevant data sequences, as
configured by ``desc``. Only with complex descriptors configured for in-place
operations with :ref:`onemkl_dft_complex_storage_real_real`.
configured by ``desc``. ``data_type`` must be single or double precision
floating-point, as described by the descriptor's precision. Only with
complex descriptors configured for in-place operations with
:ref:`onemkl_dft_complex_storage_real_real`.

out
Pointer to USM allocation of sufficient capacity to store the elements
Expand Down

0 comments on commit 2c09ad3

Please sign in to comment.