Skip to content

Commit

Permalink
chore(gpu): increase sm for rtxa6000
Browse files Browse the repository at this point in the history
  • Loading branch information
agnesLeroy committed Nov 5, 2024
1 parent a9601fc commit c1374a0
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions backends/tfhe-cuda-backend/cuda/src/device.cu
Original file line number Diff line number Diff line change
Expand Up @@ -268,17 +268,20 @@ void cuda_drop_async(void *ptr, cudaStream_t stream, uint32_t gpu_index) {
/// Get the maximum size for the shared memory
int cuda_get_max_shared_memory(uint32_t gpu_index) {
int max_shared_memory = 0;
cudaDeviceGetAttribute(&max_shared_memory, cudaDevAttrMaxSharedMemoryPerBlock,
gpu_index);
check_cuda_error(cudaGetLastError());
#if CUDA_ARCH == 900
max_shared_memory = 226000;
#elif CUDA_ARCH == 890
max_shared_memory = 100000;
#elif CUDA_ARCH == 860
max_shared_memory = 100000;
#elif CUDA_ARCH == 800
max_shared_memory = 163000;
#elif CUDA_ARCH == 700
max_shared_memory = 95000;
#else
cudaDeviceGetAttribute(&max_shared_memory, cudaDevAttrMaxSharedMemoryPerBlock,
gpu_index);
check_cuda_error(cudaGetLastError());
#endif
return max_shared_memory;
}

0 comments on commit c1374a0

Please sign in to comment.