@@ -35,8 +35,8 @@ mha_varlen_fwd(at::Tensor &q, // total_q x num_heads x head_size, total_q := \s
3535 int window_size_right,
3636 const float softcap,
3737 const bool return_softmax,
38- int num_splits ,
39- std::optional<at::Generator> gen_ );
38+ std::optional<at::Generator> gen_ ,
39+ int num_splits = 0 );
4040
4141std::vector<at::Tensor>
4242mha_fwd_kvcache (at::Tensor &q, // batch_size x seqlen_q x num_heads x head_size
@@ -110,7 +110,7 @@ TORCH_LIBRARY_EXPAND(TORCH_EXTENSION_NAME, ops) {
110110 " Tensor cu_seqlens_k, Tensor? seqused_k, Tensor? leftpad_k, Tensor? block_table, Tensor? alibi_slopes, "
111111 " int max_seqlen_q, int max_seqlen_k, float p_dropout, float softmax_scale, bool zero_tensors, "
112112 " bool is_causal, int window_size_left, int window_size_right, float softcap, bool return_softmax, "
113- " int num_splits, Generator? gen) -> Tensor[]" );
113+ " Generator? gen, int num_splits=0 ) -> Tensor[]" );
114114 ops.impl (" varlen_fwd" , torch::kCUDA , make_pytorch_shim (&mha_varlen_fwd));
115115
116116 ops.def (" fwd_kvcache(Tensor! q, Tensor kcache, Tensor vcache, Tensor? k, Tensor? v, Tensor? seqlens_k, "
0 commit comments