[Bugfix] Fix the CUDA version check for FP8 support in the CUTLASS kernels (#5715)

This commit is contained in:
Tyler Michael Smith
2024-06-20 18:36:10 +00:00
committed by GitHub
parent a7dcc62086
commit 3f3b6b2150
5 changed files with 29 additions and 12 deletions
+6
View File
@@ -144,6 +144,12 @@ TORCH_LIBRARY_EXPAND(TORCH_EXTENSION_NAME, ops) {
" Tensor b, Tensor a_scales,"
" Tensor b_scales) -> ()");
ops.impl("cutlass_scaled_mm", torch::kCUDA, &cutlass_scaled_mm);
// Check if cutlass scaled_mm is supported for CUDA devices of the given
// capability
ops.def("cutlass_scaled_mm_supports_fp8", &cutlass_scaled_mm_supports_fp8);
ops.impl("cutlass_scaled_mm_supports_fp8", torch::kCUDA,
&cutlass_scaled_mm_supports_fp8);
#endif
// Quantized GEMM for GPTQ.