Buffers - jimmytwei/oneAPI-samples GitHub Wiki
- Prefer using class template argument deductionโ
- Verbose SYCL style:โ
vector<int> v;โ
buffer<int> b(v.data(), v.size());โ
- Simplified DPC++ style (-std=c++11):โ
vector<int> v;โ
buffer<int> b(v);โ
- Simplified DPC++ style (-std=c++17):โ
vector<int> v;โ
buffer b(v);
- Prefer using class template argument deductionโ
- Verbose SYCL style:โ
- buffer<int, 2> b(ptr, range<2>(5, 5));โ
- Simplified DPC++ style (-std=c++17):โ
- buffer b(ptr, range(5, 5));