From cb594776fba3b73c325e9233abdc1ad6ddd30e39 Mon Sep 17 00:00:00 2001 From: Hugh Bird Date: Mon, 6 Nov 2023 15:26:03 +0000 Subject: [PATCH] Do not allow sub-buffers as workspaces --- source/elements/oneMKL/source/domains/dft/descriptor.rst | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/source/elements/oneMKL/source/domains/dft/descriptor.rst b/source/elements/oneMKL/source/domains/dft/descriptor.rst index 7a5cb972f..af10a4210 100644 --- a/source/elements/oneMKL/source/domains/dft/descriptor.rst +++ b/source/elements/oneMKL/source/domains/dft/descriptor.rst @@ -480,7 +480,7 @@ be used in compute calls. However, the aforementioned restrictions will still ap .. rubric:: Input Parameters workspaceBuf - A workspace buffer where ``scalar_type`` is the floating-point type according to ``prec``. This buffer must be sufficiently large or an exception will be thrown. + A workspace buffer where ``scalar_type`` is the floating-point type according to ``prec``. This buffer must be sufficiently large or an exception will be thrown. A sub-buffer cannot be used. workspaceUSM A workspace USM allocation where ``scalar_type`` is the floating-point type according to ``prec``. This allocation must be accessible on the device on which the descriptor is committed. It is assumed that this USM allocation is sufficiently large. The pointer is expected to be aligned to ``scalar_type``. @@ -492,7 +492,7 @@ be used in compute calls. However, the aforementioned restrictions will still ap The ``descriptor::set_workspace()`` routine shall throw the following exceptions if the associated condition is detected. An implementation may throw additional implementation-specific exception(s) in case of error conditions not covered here: :ref:`oneapi::mkl::invalid_argument()` - If the provided buffer ``workspaceBuf`` is not sufficiently large, or if the provided USM allocation ``workspaceUSM`` is ``nullptr`` when an external workspace of size greater than zero is required. + If the provided buffer ``workspaceBuf`` is not sufficiently large or is a sub-buffer, or if the provided USM allocation ``workspaceUSM`` is ``nullptr`` when an external workspace of size greater than zero is required. :ref:`oneapi::mkl::uninitialized()` If ``set_workspace`` is called before the descriptor is committed.