Skip to content

Commit 48fc5c0

Browse files
committed
Fix several bugs
1 parent 8bd2e90 commit 48fc5c0

3 files changed

Lines changed: 3 additions & 6 deletions

File tree

custom_ops/gpu_ops/append_attn/qwen3_rope.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,7 @@ __global__ void GQAVariableLengthRotarySplitKernel_Qwen3(
4040
const int token_idx = linear_index / offset;
4141

4242
const int ori_bi = batch_id_per_token[token_idx]; // 第几个batch
43+
if (ori_bi == -1) continue; // padded token for static/CUDA-graph shape
4344

4445
int cache_kv_len = seq_lens_decoder[ori_bi];
4546
// 这里其实是不需要处理的,但是由于FA3的bug,所以必须!

fastdeploy/envs.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -278,6 +278,8 @@ def _validate_split_kv_size(value: int) -> int:
278278
# When v1 is enabled, the legacy /clear_load_weight and /update_model_weight
279279
# will adopt this new communication pattern.
280280
"FD_ENABLE_V1_UPDATE_WEIGHTS": lambda: bool(int(os.getenv("FD_ENABLE_V1_UPDATE_WEIGHTS", "0"))),
281+
# Whether to use GDR CheckpointTransfer for dynamic weight updates.
282+
"FD_USE_GDR_CHECKPOINT_TRANSFER": lambda: bool(int(os.getenv("FD_USE_GDR_CHECKPOINT_TRANSFER", "0"))),
281283
# Whether to save the cache of output token for preempted request to storage.
282284
"FD_SAVE_OUTPUT_CACHE_FOR_PREEMPTED_REQUEST": lambda: bool(
283285
int(os.getenv("FD_SAVE_OUTPUT_CACHE_FOR_PREEMPTED_REQUEST", "1"))

fastdeploy/worker/gpu_model_runner.py

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3267,12 +3267,6 @@ def _clear_cache_for_gdr_weight_update(self):
32673267
kv_cache_status.value[0] = KVCacheStatus.CLEARING
32683268
if self.use_cudagraph:
32693269
self.model.clear_graph_opt_backend()
3270-
if envs.FD_USE_BLOCK_WISE_CUDA_GRAPH:
3271-
from fastdeploy.model_executor.graph_optimization.cuda_graph_op import (
3272-
clear_all_block_wise_graphs,
3273-
)
3274-
3275-
clear_all_block_wise_graphs()
32763270
if (
32773271
self.speculative_decoding
32783272
and self.spec_method == SpecMethod.MTP

0 commit comments

Comments
 (0)