sync#

Wait for any code running on an executor to complete.

inline void matx::cudaExecutor::sync()#

Synchronize the cuda executor’s stream.

inline void matx::HostExecutor::sync()#

Synchronize the host executor’s threads.

Examples#

(Bout = matvec(A, X)).run(exec);
(norm = sum((Bout-B)*(Bout-B))).run(exec);
(maxn = matx::max(sqrt(norm))).run(exec);

exec.sync();