oneapi-src / oneapi-src/oneAPI-samples

Unable to run sample SYCL program

未关闭
#1,337 7 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

还没有人认领这个 Issue。

bug
主要语言
C++
星标
1.2k
派生
745
PR 合并指标
30 天内没有已合并 PR

描述

Summary

I have built SYCL compiler from the source. I was trying out the example given in the below documentation :
https://intel.github.io/llvm-docs/GetStartedGuide.html#run-simple-dpc-application

After building the compiler from source, I have updated my environment as suggested

export PATH=$DPCPP_HOME/llvm/build/bin:$PATH
export LD_LIBRARY_PATH=$DPCPP_HOME/llvm/build/lib:$LD_LIBRARY_PATH

I could build the binary successfully, however on running that executable , I am getting below error

Command used to generate binary
clang++ -fsycl simple_sycl.cpp -o syc

./syc
terminate called after throwing an instance of 'sycl::_V1::runtime_error'
  what():  No device of requested type available. -1 (PI_ERROR_DEVICE_NOT_FOUND)
Aborted (core dumped)

Version

Tip commit of git
3df87e20569ea63d0a74de525b6d19788dd8afca

Environment

OS
Ubuntu 20.04.3 LTS

CPU information

Architecture:                    x86_64
CPU op-mode(s):                  32-bit, 64-bit
Byte Order:                      Little Endian
Address sizes:                   43 bits physical, 48 bits virtual
CPU(s):                          12
On-line CPU(s) list:             0-11
Thread(s) per core:              1
Core(s) per socket:              1
Socket(s):                       12
NUMA node(s):                    1
Vendor ID:                       GenuineIntel
CPU family:                      6
Model:                           85
Model name:                      Intel(R) Xeon(R) Gold 5220R CPU @ 2.20GHz
Stepping:                        0
CPU MHz:                         2194.844

Steps to reproduce

Command used to generate binary
clang++ -fsycl simple_sycl.cpp -o syc
./syc

Observed behavior

I am suspecting missing runtime libraries.

贡献指南

打开贡献指南

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

调研方向

从 issue 中链接的 GetStartedGuide 开始,然后检查用于构建和运行 simple_sycl.cpp 的命令,以及报告的 PI_ERROR_DEVICE_NOT_FOUND 消息。确认文档中描述的环境和运行时库是否在所述的 Ubuntu CPU 系统上提供可用设备;样例可执行文件成功运行即表示完成。

由索引模型根据 Issue 内容生成。

评估

技术栈
cpp, ubuntu
领域
developer-experience, operating-systems
Issue 类型
缺陷
难度
4/5
预计耗时
3-5 天
活跃度
停滞
描述清晰度
需要澄清
新手友好度
30/100

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。