inline void dispatch_fill(svm_ptr<T> first, size_t count, const T &value, command_queue &queue) { if(count == 0){ return; } queue.enqueue_svm_fill( first.get(), &value, sizeof(T), count * sizeof(T) ); }
inline future<void> dispatch_fill_async(svm_ptr<T> first, size_t count, const T &value, command_queue &queue) { if(count == 0){ return future<void>(); } event event_ = queue.enqueue_svm_fill( first.get(), &value, sizeof(T), count * sizeof(T) ); return future<void>(event_); }