Fix memory leak in prefill delayer (#16358)

This commit is contained in:
fzyzcjy
2026-01-04 10:11:18 +08:00
committed by GitHub
parent 9bd64d739b
commit 5d4b7c78bf
2 changed files with 7 additions and 11 deletions

View File

@@ -1929,10 +1929,10 @@ class Scheduler(
if self.prefill_delayer
else True
)
if (not delayer_allow_prefill) or (
(self.running_batch.batch_is_full or len(self.waiting_queue) == 0)
and self.chunked_req is None
):
if (
(not delayer_allow_prefill)
or ((self.running_batch.batch_is_full or len(self.waiting_queue) == 0))
) and self.chunked_req is None:
return None
running_bs = len(self.running_batch.reqs)