diff options
| author | Claudius "keldu" Holeksa <mail@keldu.de> | 2026-04-29 18:57:40 +0200 |
|---|---|---|
| committer | Claudius "keldu" Holeksa <mail@keldu.de> | 2026-04-29 18:57:40 +0200 |
| commit | 4f47c2c5631b6cadef3a74eca52bb40a3c5f75a9 (patch) | |
| tree | 1fc847ffefe62ae64cc63cbfaddb10e77835e373 /lib/sycl/c++ | |
| parent | b74db86c59c75936e2a2ee270939cbc42652acbf (diff) | |
| parent | a3522ffb6c1020f88ac1acf3b5bf6001b9275503 (diff) | |
| download | libs-lbm-4f47c2c5631b6cadef3a74eca52bb40a3c5f75a9.tar.gz | |
Merge branch 'dev'
Diffstat (limited to 'lib/sycl/c++')
| -rw-r--r-- | lib/sycl/c++/index.hpp | 18 | ||||
| -rw-r--r-- | lib/sycl/c++/sycl.hpp | 1 |
2 files changed, 19 insertions, 0 deletions
diff --git a/lib/sycl/c++/index.hpp b/lib/sycl/c++/index.hpp new file mode 100644 index 0000000..0d2c035 --- /dev/null +++ b/lib/sycl/c++/index.hpp @@ -0,0 +1,18 @@ +#pragma once + +#include "common.hpp" + +namespace kel { +namespace lbm { +template<typename D> +saw::data<sch::FixedArray<sch::UInt64,D>> sycl_to_saw_index(const acpp::sycl::id<D>& idx){ + saw::data<sch::FixedArray<sch::UInt64,D>> trans_index; + + for(uint64_t i{0u}; i < D; ++i){ + trans_index.at({{i}}).set(idx[i]); + } + + return trans_index; +} +} +} diff --git a/lib/sycl/c++/sycl.hpp b/lib/sycl/c++/sycl.hpp index 8ddc3cd..973b511 100644 --- a/lib/sycl/c++/sycl.hpp +++ b/lib/sycl/c++/sycl.hpp @@ -2,3 +2,4 @@ #include "common.hpp" #include "data.hpp" +#include "index.hpp" |
