diff --git a/SYCLStream.cpp b/SYCLStream.cpp index e0fce5d..049c26e 100644 --- a/SYCLStream.cpp +++ b/SYCLStream.cpp @@ -215,9 +215,9 @@ void SYCLStream::init_arrays(T initA, T initB, T initC) template void SYCLStream::read_arrays(std::vector& a, std::vector& b, std::vector& c) { - auto _a = d_a->template get_access(); - auto _b = d_b->template get_access(); - auto _c = d_c->template get_access(); + sycl::host_accessor _a {*d_a, sycl::read_only}; + sycl::host_accessor _b {*d_b, sycl::read_only}; + sycl::host_accessor _c {*d_c, sycl::read_only}; for (int i = 0; i < array_size; i++) { a[i] = _a[i];