Skip to content

Commit

Permalink
remove dead code in SummaryOps.cu
Browse files Browse the repository at this point in the history
  • Loading branch information
yuantailing committed Mar 23, 2023
1 parent 6b9b382 commit 15c18f0
Showing 1 changed file with 0 additions and 10 deletions.
10 changes: 0 additions & 10 deletions aten/src/ATen/native/cuda/SummaryOps.cu
Original file line number Diff line number Diff line change
Expand Up @@ -154,16 +154,6 @@ __global__ void kernelHistogram1D(
HANDLE_CASE(CUDAHistogramMemoryType::GLOBAL, getOp, 0); \
}

inline int64_t getFreeGlobalMemory() {
// no need to use `cudaSetDevice`
size_t free_mem, total_mem;
cudaMemGetInfo(&free_mem, &total_mem);
TORCH_INTERNAL_ASSERT(
cudaGetLastError() == cudaSuccess,
"CUDA_tensor_histogram failed to get free global memory");
return static_cast<int64_t>(free_mem);
}

/*
Calculate the frequency of the input values.
Expand Down

0 comments on commit 15c18f0

Please sign in to comment.