Skip to content

Commit 258bf62

Browse files
luccafongLucia (Lu) Fang
and
Lucia (Lu) Fang
authored
fix CUDA_check redefinition in #17918 (#18287)
Signed-off-by: Lucia Fang <[email protected]> Co-authored-by: Lucia (Lu) Fang <[email protected]>
1 parent dc1440c commit 258bf62

File tree

2 files changed

+5
-12
lines changed

2 files changed

+5
-12
lines changed

csrc/cutlass_extensions/common.hpp

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -15,15 +15,6 @@
1515
cutlassGetStatusString(error)); \
1616
}
1717

18-
/**
19-
* Panic wrapper for unwinding CUDA runtime errors
20-
*/
21-
#define CUDA_CHECK(status) \
22-
{ \
23-
cudaError_t error = status; \
24-
TORCH_CHECK(error == cudaSuccess, cudaGetErrorString(error)); \
25-
}
26-
2718
inline int get_cuda_max_shared_memory_per_block_opt_in(int const device) {
2819
int max_shared_mem_per_block_opt_in = 0;
2920
cudaDeviceGetAttribute(&max_shared_mem_per_block_opt_in,

csrc/sparse/cutlass/sparse_scaled_mm_c3x.cuh

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,8 @@
88

99
#include <ATen/cuda/CUDAContext.h>
1010

11+
#include "cuda_utils.h"
12+
1113
#include "cutlass/cutlass.h"
1214

1315
#include "cutlass/gemm/device/gemm_universal_adapter.h"
@@ -95,9 +97,9 @@ struct cutlass_sparse_3x_gemm {
9597
// clang-format off
9698
using CollectiveMainloop =
9799
typename cutlass::gemm::collective::CollectiveBuilder<
98-
cutlass::arch::Sm90, cutlass::arch::OpClassSparseTensorOp,
99-
ElementAB, cutlass::layout::RowMajor, AlignmentAB,
100-
ElementAB, cutlass::layout::ColumnMajor, AlignmentAB,
100+
cutlass::arch::Sm90, cutlass::arch::OpClassSparseTensorOp,
101+
ElementAB, cutlass::layout::RowMajor, AlignmentAB,
102+
ElementAB, cutlass::layout::ColumnMajor, AlignmentAB,
101103
ElementAcc, TileShape, ClusterShape,
102104
Stages,
103105
KernelSchedule>::CollectiveOp;

0 commit comments

Comments
 (0)