| 23 | namespace gpu { |
| 24 | |
| 25 | bool GpuStream::Init() { |
| 26 | if (!GpuDriver::CreateStream(parent_->gpu_context(), &gpu_stream_, |
| 27 | priority_)) { |
| 28 | return false; |
| 29 | } |
| 30 | return GpuDriver::InitEvent(parent_->gpu_context(), &completed_event_, |
| 31 | GpuDriver::EventFlags::kDisableTiming) |
| 32 | .ok(); |
| 33 | } |
| 34 | |
| 35 | void GpuStream::Destroy() { |
| 36 | if (completed_event_ != nullptr) { |
nothing calls this directly
no test coverage detected