src/
Coverage:
low: ≥ 0%
medium: ≥ 75.0%
high: ≥ 90.0%
Lines:
0 / 8
0.0%
Branches:
0 / 2
0.0%
Functions:
0 / 4
0.0%

framework/pytorch/op_cuda_runtime_cpu.cc
Line Branch Exec Source
1 #include "framework/pytorch/op_cuda_runtime.h"
2
3 // CPU-only fallback for builds without a CUDA toolkit: the stream
4 // synchronization is a no-op and page-locking always reports failure so the
5 // callers take their non-pinned path.
6
7 namespace recstore {
8 namespace framework {
9
10 std::function<void()>
11 ✗ RecordCudaCompletionForTensor(const torch::Tensor& tensor) {
12
0/2
✗ Branch 1 not taken.
✗ Branch 2 not taken.
✗ TORCH_CHECK(!tensor.is_cuda(), "CUDA staging requires a CUDA build");
13 ✗ return [] {};
14 }
15
16 ✗ void SynchronizeCurrentCudaStreamForTensor(const torch::Tensor& tensor) {
17 (void)tensor;
18 ✗ }
19
20 ✗ void RetainUntilCudaComplete(const torch::Tensor&,
21 std::function<void()> release) {
22 ✗ release();
23 ✗ }
24
25 } // namespace framework
26 } // namespace recstore
27