-
Notifications
You must be signed in to change notification settings - Fork 797
Closed
Labels
Description
Describe the bug
test.cpp:
#include <iostream>
#include <sycl/sycl.hpp>
#include <sycl/ext/intel/fpga_extensions.hpp>
// Test for using sycl::ext::intel::pipe and sycl::ext::intel::experimental::pipe in the
// same kernel.
using SYCLPipe = sycl::ext::intel::pipe<class PipeA, int>;
using ExpPipe = sycl::ext::intel::experimental::pipe<class PipeB, short>;
int main() {
sycl::queue q(sycl::ext::intel::fpga_emulator_selector{});
q.submit([&](sycl::handler &cgh) {
cgh.single_task<class SimplePipeWrite>([=]() {
SYCLPipe::write(42);
ExpPipe::write(24);
});
});
q.wait();
int a = 0;
short b = 0;
sycl::buffer<int, 1> buf_a(&a, 1);
sycl::buffer<short, 1> buf_b(&b, 1);
q.submit([&](sycl::handler &cgh) {
auto acc_a = buf_a.get_access<sycl::access::mode::write>(cgh);
auto acc_b = buf_b.get_access<sycl::access::mode::write>(cgh);
cgh.single_task<class SimplePipeRead>([=]() {
acc_a[0] = SYCLPipe::read();
acc_b[0] = ExpPipe::read();
});
});
q.wait();
if (a != 42 || b != 24) {
std::cout << "Failed\n";
return 1;
}
std::cout << "Passed\n";
return 0;
}
JIT compilation failed with the following error:
# .---command stderr------------
# | terminate called after throwing an instance of 'sycl::_V1::compile_program_error'
# | what(): The program was built for 1 devices
# | Build program log for 'Intel(R) FPGA Emulation Device':
# | Compilation started
# | Compilation done
# | Linking started
# | Linking done
# | Device build started
# | Options used by backend compiler:
# | Failed to build device program
# | CompilerException Failed to lookup symbol _ZTSZZ4mainENKUlRN4sycl3_V17handlerEE_clES2_E15SimplePipeWrite
# | JIT session error: Symbols not found: [ _Z38__spirv_CreatePipeFromPipeStorage_readPU3AS427__spirv_ConstantPipeStorage.2, _Z39__spirv_CreatePipeFromPipeStorage_writePU3AS427__spirv_ConstantPipeStorage.1 ]
# | Failed to materialize symbols: { (main, { $.main.__inits.0, _ZN4sycl3_V13ext5intel12experimental4pipeI5PipeBsLi0ENS1_6oneapi12experimental10propertiesISt5tupleIJEEEEvE9m_StorageE.syclpipe, _ZN4sycl3_V13ext5intel12experimental4pipeI5PipeBsLi0ENS1_6oneapi12experimental10propertiesISt5tupleIJEEEEvE9m_StorageE.syclpipe.4.bs, _ZTSZZ4mainENKUlRN4sycl3_V17handlerEE_clES2_E15SimplePipeWrite, __orc_init_func.main, _ZN4sycl3_V13ext5intel4pipeI5PipeAiLi0EE9m_StorageE.syclpipe.3, _ZN4sycl3_V13ext5intel4pipeI5PipeAiLi0EE9m_StorageE.syclpipe.3.bs, __pipe_global_ctor, _ZN4sycl3_V13ext5intel4pipeI5PipeAiLi0EE9m_StorageE.syclpipe, _ZN4sycl3_V13ext5intel12experimental4pipeI5PipeBsLi0ENS1_6oneapi12experimental10propertiesISt5tupleIJEEEEvE9m_StorageE.syclpipe.bs, _ZN4sycl3_V13ext5intel4pipeI5PipeAiLi0EE9m_StorageE.syclpipe.bs, _ZN4sycl3_V13ext5intel12experimental4pipeI5PipeBsLi0ENS1_6oneapi12experimental10propertiesISt5tupleIJEEEEvE9m_StorageE.syclpipe.4, _ZTSZZ4mainENKUlRN4sycl3_V17handlerEE0_clES2_E14SimplePipeRead }) }
# |
# | -11 (PI_ERROR_BUILD_PROGRAM_FAILURE)
# `-----------------------------
# error: command failed with exit status: -6
To reproduce
Reproduce steps:
clang++ -fsycl test.cpp -o a.out
env ONEAPI_DEVICE_SELECTOR=opencl:fpga ./a.out
Error:
terminate called after throwing an instance of 'sycl::_V1::compile_program_error'
what(): The program was built for 1 devices
Build program log for 'Intel(R) FPGA Emulation Device':
Compilation started
Compilation done
Linking started
Linking done
Device build started
Options used by backend compiler:
Failed to build device program
CompilerException Failed to lookup symbol _ZTSZZ4mainENKUlRN4sycl3_V17handlerEE_clES2_E15SimplePipeWrite
JIT session error: Symbols not found: [ _Z38__spirv_CreatePipeFromPipeStorage_readPU3AS427__spirv_ConstantPipeStorage.2, _Z39__spirv_CreatePipeFromPipeStorage_writePU3AS427__spirv_ConstantPipeStorage.1 ]
Failed to materialize symbols: { (main, { __orc_init_func.main, _ZN4sycl3_V13ext5intel12experimental4pipeI5PipeBsLi0ENS1_6oneapi12experimental10propertiesISt5tupleIJEEEEvE9m_StorageE.syclpipe.4, _ZTSZZ4mainENKUlRN4sycl3_V17handlerEE_clES2_E15SimplePipeWrite, _ZN4sycl3_V13ext5intel4pipeI5PipeAiLi0EE9m_StorageE.syclpipe.3.bs, __pipe_global_ctor, $.main.__inits.0, _ZN4sycl3_V13ext5intel12experimental4pipeI5PipeBsLi0ENS1_6oneapi12experimental10propertiesISt5tupleIJEEEEvE9m_StorageE.syclpipe, _ZTSZZ4mainENKUlRN4sycl3_V17handlerEE0_clES2_E14SimplePipeRead, _ZN4sycl3_V13ext5intel12experimental4pipeI5PipeBsLi0ENS1_6oneapi12experimental10propertiesISt5tupleIJEEEEvE9m_StorageE.syclpipe.4.bs, _ZN4sycl3_V13ext5intel4pipeI5PipeAiLi0EE9m_StorageE.syclpipe.bs, _ZN4sycl3_V13ext5intel4pipeI5PipeAiLi0EE9m_StorageE.syclpipe.3, _ZN4sycl3_V13ext5intel4pipeI5PipeAiLi0EE9m_StorageE.syclpipe, _ZN4sycl3_V13ext5intel12experimental4pipeI5PipeBsLi0ENS1_6oneapi12experimental10propertiesISt5tupleIJEEEEvE9m_StorageE.syclpipe.bs }) }
-11 (PI_ERROR_BUILD_PROGRAM_FAILURE)
[1] 276021 IOT instruction (core dumped) env ONEAPI_DEVICE_SELECTOR=opencl:fpga ./a.out
Environment
- OS: Linux
- Target: Intel FPGA emulator
- Clang++ version: 9b4bf7c
sycl-ls --verbose
INFO: Output filtered by SYCL_DEVICE_ALLOWLIST environment variable, which is set to BackendName:level_zero|opencl.
To see device ids, use the --ignore-device-selectors CLI option.
[opencl:fpga] Intel(R) FPGA Emulation Platform for OpenCL(TM), Intel(R) FPGA Emulation Device OpenCL 1.2 [2024.17.3.0.09_160000]
Platforms: 1
Platform [#1]:
Version : OpenCL 1.2 Intel(R) FPGA SDK for OpenCL(TM), Version 20.3
Name : Intel(R) FPGA Emulation Platform for OpenCL(TM)
Vendor : Intel(R) Corporation
Devices : 1
Type : fpga
Version : OpenCL 1.2
Name : Intel(R) FPGA Emulation Device
Vendor : Intel(R) Corporation
Driver : 2024.17.3.0.09_160000
Aspects : accelerator fp64 online_compiler online_linker queue_profiling usm_device_allocations usm_host_allocations usm_shared_allocations usm_atomic_host_allocations usm_atomic_shared_allocations ext_oneapi_srgb ext_oneapi_ballot_group ext_oneapi_fixed_size_group ext_oneapi_opportunistic_group ext_oneapi_tangle_group ext_intel_fpga_task_sequence ext_oneapi_private_alloca
info::device::sub_group_sizes: 4 8 16 32 64
default_selector() : fpga, Intel(R) FPGA Emulation Platform for OpenCL(TM), Intel(R) FPGA Emulation Device OpenCL 1.2 [2024.17.3.0.09_160000]
accelerator_selector() : fpga, Intel(R) FPGA Emulation Platform for OpenCL(TM), Intel(R) FPGA Emulation Device OpenCL 1.2 [2024.17.3.0.09_160000]
cpu_selector() : No device of requested type available. -1 (PI_ERRO...
gpu_selector() : No device of requested type available. -1 (PI_ERRO...
custom_selector(gpu) : No device of requested type available. -1 (PI_ERRO...
custom_selector(cpu) : No device of requested type available. -1 (PI_ERRO...
custom_selector(acc) : fpga, Intel(R) FPGA Emulation Platform for OpenCL(TM), Intel(R) FPGA Emulation Device OpenCL 1.2 [2024.17.3.0.09_160000]
Additional context
No response