I am new to the oneAPI with SYCL and I have the following function
q.submit([&](auto &h) {
h.parallel_for(range<1>(size), [=](id<1> idx) {
m_Add(C,A,B,idx);
m_Multiply(D,C,A,idx);
});
}).wait();
I understand that the parallel_for function acts like
for(int idx = 0; idx < size; idx++)
I would like to run these m_Add
and m_Multiply
functions depending on a while loop condition like D < A
so the parallel_for function runs while(D < A)
Is it possible to achieve this with any other function that the accelarator executes these functions within a while loop ?