Skip to content

CTS handler_copy fail with CUDA backend #3969

Closed
@XunZhangIntel

Description

@XunZhangIntel

Describe the bug
CTS handler_copy fail with CUDA backend on latest SYCL builds. See logs below:

PI CUDA ERROR:
    Value:           1
    Name:            CUDA_ERROR_INVALID_VALUE
    Description:     invalid argument
    Function:        commonEnqueueMemBufferCopyRect
    Source Location: sycl/plugins/cuda/pi_cuda.cpp:3524

  . line: 777
  . copy(shared_ptr_class<int>, accessor<int, 2, write, global_buffer>) [strided] failed: Exception thrown during call:
  . sycl exception caught
  . what - OpenCL API failed. OpenCL API returns: -30 (CL_INVALID_VALUE) -30 (CL_INVALID_VALUE)
  . line: 967
  . a SYCL exception was caught: OpenCL API failed. OpenCL API returns: -30 (CL_INVALID_VALUE) -30 (CL_INVALID_VALUE)
  - fail

To Reproduce
Note: Due to a recent uplift of minimal supported C++ standard, one should modify this line to require C++17.

  1. Get SYCL with CUDA support (GSG) and SYCL-CTS
  2. Build CTS tests
cd SYCL-CTS
mkdir build && cd build
cmake -GNinja  -DSYCL_IMPLEMENTATION=Intel_SYCL -DINTEL_SYCL_ROOT=<path to built sycl> -Dopencl_platform_name=nvidia -Dopencl_device_name=opencl_gpu -DCMAKE_BUILD_TYPE=Release -DINTEL_SYCL_FLAGS="-Xsycl-target-backend;--cuda-gpu-arch=sm_50" -DCMAKE_EXE_LINKER_FLAGS=" -Wl,-no-relax " -DINTEL_SYCL_TRIPLE=nvptx64-nvidia-cuda-sycldevice -DSYCL_CTS_ENABLE_OPENCL_INTEROP_TESTS=Off -DSYCL_CTS_ENABLE_DOUBLE_TESTS=On -DSYCL_CTS_ENABLE_HALF_TESTS=On ..
ninja test_handler
  1. Run Test
SYCL_DEVICE_FILTER="cuda:gpu:0" ./bin/test_handler -p nvidia -d opencl_gpu  --test handler_copy

Environment (please complete the following information):
OS version: Ubuntu 18.04.5 LTS (Bionic Beaver)
CUDA version:

nvidia-smi

+-----------------------------------------------------------------------------+
| NVIDIA-SMI 435.21       Driver Version: 435.21       CUDA Version: 10.1     |
|-------------------------------+----------------------+----------------------+

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingcudaCUDA back-endruntimeRuntime library related issue

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions