Skip to content

Commit 30d0322

Browse files
SnowCharmQadobrzyn
authored andcommitted
[Perf] Optimize _update_states for GPU model runner (vllm-project#16910)
Signed-off-by: snowcharm <[email protected]> Signed-off-by: Agata Dobrzyniewicz <[email protected]>
1 parent c63d7fc commit 30d0322

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

vllm/v1/worker/gpu_model_runner.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -454,7 +454,7 @@ def _update_states(self, scheduler_output: "SchedulerOutput") -> None:
454454

455455
# Add the new or resumed requests to the persistent batch.
456456
# The smaller empty indices are filled first.
457-
removed_req_indices = sorted(removed_req_indices, reverse=True)
457+
removed_req_indices.sort(reverse=True)
458458
for req_id in req_ids_to_add:
459459
req_state = self.requests[req_id]
460460
if removed_req_indices:

0 commit comments

Comments
 (0)