Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
Signed-off-by: Cody Yu <[email protected]>
  • Loading branch information
comaniac committed Nov 4, 2024
1 parent 62354d7 commit 87f5195
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
4 changes: 2 additions & 2 deletions vllm/v1/core/kv_cache_manager.py
Original file line number Diff line number Diff line change
Expand Up @@ -68,10 +68,10 @@ def __init__(self, blocks: List[KVCacheBlock]) -> None:
# Initialize the doubly linked list of free blocks.
self.free_list_head = blocks[0]
self.free_list_tail = blocks[-1]
for i in range(self.size):
for i in range(self.num_free_blocks):
if i > 0:
blocks[i].prev_free_block = blocks[i - 1]
if i < self.size - 1:
if i < self.num_free_blocks - 1:
blocks[i].next_free_block = blocks[i + 1]

def popleft(self) -> KVCacheBlock:
Expand Down
1 change: 0 additions & 1 deletion vllm/v1/core/scheduler.py
Original file line number Diff line number Diff line change
Expand Up @@ -210,7 +210,6 @@ def schedule(self) -> "SchedulerOutput":
)

self.finished_req_ids = set()
self.kv_cache_manager.async_remove_touched_blocks()
return scheduler_output

def _make_running_request_data(
Expand Down

0 comments on commit 87f5195

Please sign in to comment.