Closed Ralender closed 2 years ago
To be rebased somehow on unified/next
?
To be rebased somehow on
unified/next
?
I rebased it but this is still a draft.
Can you push your latest version?
Pushed but still experimental.
now all test pass with the xrt plugin so it is probably not experimental anymore
This commit doesn't address the review, it was just a cleanup commit I thought I had pushed before your review.
github's handling of force push seems kind of bad...
I have some problems using this with your example I have simplified to https://github.com/keryell/heterogeneous_examples/blob/main/vector_add/SYCL/vector_add_XRT_interoperability.cpp
~/Xilinx/Projects/LLVM/worktrees/xilinx/llvm/build/bin/clang++ -Wall -std=c++2b -g -g3 -fsycl -fsycl-targets=fpga64_hls_hw_emu -I/opt/xilinx/xrt/include -L/opt/xilinx/xrt/lib -lOpenCL -luuid -lxrt_coreutil -fsycl vector_add_XRT_interoperability.cpp -o vector_add_XRT_interoperability
In file included from vector_add_XRT_interoperability.cpp:2:
/home/rkeryell/Xilinx/Projects/LLVM/worktrees/xilinx/llvm/build/bin/../include/sycl/ext/xilinx/xrt.hpp:59:8: error: unknown type name 'device'
inline device make_device<backend::xrt>(
^
/home/rkeryell/Xilinx/Projects/LLVM/worktrees/xilinx/llvm/build/bin/../include/sycl/ext/xilinx/xrt.hpp:59:27: error: use of undeclared identifier 'backend'; did you mean 'sycl::backend'?
inline device make_device<backend::xrt>(
^
/home/rkeryell/Xilinx/Projects/LLVM/worktrees/xilinx/llvm/build/bin/../include/sycl/CL/sycl/backend_types.hpp:21:12: note: 'sycl::backend' declared here
enum class backend : char {
^
In file included from vector_add_XRT_interoperability.cpp:2:
/home/rkeryell/Xilinx/Projects/LLVM/worktrees/xilinx/llvm/build/bin/../include/sycl/ext/xilinx/xrt.hpp:60:27: error: use of undeclared identifier 'backend'; did you mean 'sycl::backend'?
const backend_input_t<backend::xrt, device> &BackendObject) {
^
/home/rkeryell/Xilinx/Projects/LLVM/worktrees/xilinx/llvm/build/bin/../include/sycl/CL/sycl/backend_types.hpp:21:12: note: 'sycl::backend' declared here
enum class backend : char {
^
In file included from vector_add_XRT_interoperability.cpp:2:
/home/rkeryell/Xilinx/Projects/LLVM/worktrees/xilinx/llvm/build/bin/../include/sycl/ext/xilinx/xrt.hpp:60:41: error: use of undeclared identifier 'device'
const backend_input_t<backend::xrt, device> &BackendObject) {
^
etc.
I fixed the issue you where having an resolved the merge conflict
I still have a problem:
-<2:%>- make vector_add_XRT_interoperability
~/Xilinx/Projects/LLVM/worktrees/xilinx/llvm/build/bin/clang++ -Wall -std=c++2b -g -g3 -fsycl -fsycl-targets=fpga64_hls_hw_emu -I/opt/xilinx/xrt/include -L/opt/xilinx/xrt/lib -lOpenCL -luuid -lxrt_coreutil -fsycl vector_add_XRT_interoperability.cpp -o vector_add_XRT_interoperability
In file included from vector_add_XRT_interoperability.cpp:2:
In file included from /home/rkeryell/Xilinx/Projects/LLVM/worktrees/xilinx/llvm/build/bin/../include/sycl/ext/xilinx/xrt.hpp:11:
/home/rkeryell/Xilinx/Projects/LLVM/worktrees/xilinx/llvm/build/bin/../include/sycl/CL/sycl/backend.hpp:54:3: error: implicit instantiation of undefined template 'sycl::detail::BackendInput<sycl::backend::xrt, sycl::device>'
using input_type = typename detail::BackendInput<Backend, T>::type;
^
/home/rkeryell/Xilinx/Projects/LLVM/worktrees/xilinx/llvm/build/bin/../include/sycl/CL/sycl/backend.hpp:63:1: note: in instantiation of template type alias 'input_type' requested here
using backend_input_t =
^
/home/rkeryell/Xilinx/Projects/LLVM/worktrees/xilinx/llvm/build/bin/../include/sycl/ext/xilinx/xrt.hpp:61:11: note: in instantiation of template type alias 'backend_input_t' requested here
const backend_input_t<backend::xrt, device> &BackendObject) {
^
/home/rkeryell/Xilinx/Projects/LLVM/worktrees/xilinx/llvm/build/bin/../include/sycl/CL/sycl/detail/backend_traits.hpp:20:47: note: template is declared here
template <backend Backend, typename T> struct BackendInput;
^
In file included from vector_add_XRT_interoperability.cpp:2:
In file included from /home/rkeryell/Xilinx/Projects/LLVM/worktrees/xilinx/llvm/build/bin/../include/sycl/ext/xilinx/xrt.hpp:11:
/home/rkeryell/Xilinx/Projects/LLVM/worktrees/xilinx/llvm/build/bin/../include/sycl/CL/sycl/backend.hpp:54:3: error: implicit instantiation of undefined template 'sycl::detail::BackendInput<sycl::backend::xrt, sycl::device>'
using input_type = typename detail::BackendInput<Backend, T>::type;
^
/home/rkeryell/Xilinx/Projects/LLVM/worktrees/xilinx/llvm/build/bin/../include/sycl/CL/sycl/backend.hpp:63:1: note: in instantiation of template type alias 'input_type' requested here
using backend_input_t =
^
/home/rkeryell/Xilinx/Projects/LLVM/worktrees/xilinx/llvm/build/bin/../include/sycl/ext/xilinx/xrt.hpp:63:32: note: in instantiation of template type alias 'backend_input_t' requested here
detail::to_native_handle<backend_input_t<backend::xrt, device>>(
^
/home/rkeryell/Xilinx/Projects/LLVM/worktrees/xilinx/llvm/build/bin/../include/sycl/CL/sycl/detail/backend_traits.hpp:20:47: note: template is declared here
template <backend Backend, typename T> struct BackendInput;
@Ralender it would be interesting to see how it works in respect to the presentation from @TApplencourt, @illuhad,... at SYCLcon 2022 SYCL Concurrency on GPU Platforms: Empirical Measurement https://www.youtube.com/watch?v=VqiY-KZXATc&list=PL46sP9LM8GsyHAxj1k7MbWrv5f5SlMpIF&index=19
I read through the PR for xrt::hw_context
and I don't think it is something we need or would benefit to use. and since it is supposed to work as is for existing code I don't think we need to update anything because of it.
Nice to have some new documentation! It looks like there are still some comments from me that went unnoticed.
yeah I fixed what you asked for but in an other worktree without noticing so the edits you asked are in the pipe PR but not this one. it is fixed it now. and I am looking at new comments.
This is based on top of https://github.com/triSYCL/sycl/pull/162.
The plugin is not complete. This is still a work in progress.