-
Notifications
You must be signed in to change notification settings - Fork 798
Closed
oneapi-src/unified-memory-framework
#1086Labels
Description
Describe the bug
Trying to profile a SYCL application under nsys profile
seems to be broken after #16761, where urPlatformGet()
fails with an unknown error when calling CreateDeviceMemoruyProviders()
. This makes it impossible to profile using nsys
, while the application executes normally when run directly.
Error output:
nsys profile ./usm_fill
Collecting data...
<CUDA>[ERROR]:
UR ERROR:
Value: UR_RESULT_ERROR_UNKNOWN
Function: operator()
Source Location: <llvm build dir>/_deps/unified-runtime-src/source/adapters/cuda/platform.cpp:137
terminate called after throwing an instance of 'sycl::_V1::exception'
what(): Native API failed. Native API returns: 2147483646 (UR_RESULT_ERROR_UNKNOWN)
Generating '/tmp/nsys-report-bb87.qdstrm'
[1/1] [========================100%] report1.nsys-rep
Generated:
./report1.nsys-rep
To reproduce
Example commands to reproduce from LLVM build with an E2E test:
cd <llvm build dir>
./bin/clang++ -fsycl -fsycl-targets=nvptx64-nvidia-cuda ../sycl/test-e2e/Graph/Explicit/usm_fill.cpp -o usm_fill
export LD_LIBRARY_PATH=<llvm build dir>/lib/:$LD_LIBRARY_PATH
export ONEAPI_DEVICE_SELECTOR=cuda:gpu
# Executes fine
./usm_fill
# Fails
nsys profile ./usm_fill
Environment
- OS: Linux
- Target device and vendor: [e.g. Nvidia GPU]
- DPC++ version: 2be11a1
- Dependencies version: Tested on both CUDA 12.3 and 12.5 and
nsys
version2024.6.2.225-246235244400v0
and2025.1.1.103-251135427971v0
Additional context
Reproduced on two different systems so local configuration doesn't seem to be the issue, and nsys profile
works fine from commits before the linked PR.