Skip to content

Commit 8ce5d31

Browse files
robertgshaw2-redhatSageMoorerussellbNiuBlibingIsotr0py
authored andcommitted
[P/D] NIXL Updates (#25844)
Signed-off-by: Sage Moore <sage@neuralmagic.com> Signed-off-by: simon-mo <simon.mo@hey.com> Signed-off-by: rentianyue-jk <rentianyue-jk@360shuke.com> Signed-off-by: Russell Bryant <rbryant@redhat.com> Signed-off-by: Isotr0py <mozf@mail2.sysu.edu.cn> Signed-off-by: Chenheli Hua <huachenheli@outlook.com> Signed-off-by: mgoin <mgoin64@gmail.com> Signed-off-by: Tyler Michael Smith <tlrmchlsmth@gmail.com> Signed-off-by: NickLucche <nlucches@redhat.com> Signed-off-by: Roger Wang <hey@rogerw.io> Signed-off-by: Robert Shaw <robshaw@redhat.com> Co-authored-by: Sage Moore <sage@neuralmagic.com> Co-authored-by: Russell Bryant <rbryant@redhat.com> Co-authored-by: rentianyue-jk <rentianyue-jk@360shuke.com> Co-authored-by: Isotr0py <mozf@mail2.sysu.edu.cn> Co-authored-by: Chenheli Hua <huachenheli@outlook.com> Co-authored-by: Wentao Ye <44945378+yewentao256@users.noreply.github.com> Co-authored-by: Michael Goin <mgoin64@gmail.com> Co-authored-by: Tyler Michael Smith <tlrmchlsmth@gmail.com> Co-authored-by: Nicolò Lucchesi <nlucches@redhat.com> Co-authored-by: Roger Wang <hey@rogerw.io> Co-authored-by: Robert Shaw <robshaw@redhat.com> Signed-off-by: simon-mo <simon.mo@hey.com>
1 parent 09c2cbc commit 8ce5d31

File tree

2 files changed

+11
-3
lines changed

2 files changed

+11
-3
lines changed

vllm/distributed/kv_transfer/kv_connector/v1/nixl_connector.py

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -474,8 +474,11 @@ def __init__(self, vllm_config: VllmConfig, engine_id: str):
474474
"backends", ["UCX"])
475475
# Agent.
476476
non_ucx_backends = [b for b in self.nixl_backends if b != "UCX"]
477-
config = nixl_agent_config(backends=self.nixl_backends) if len(
478-
non_ucx_backends) > 0 and nixl_agent_config is not None else None
477+
if nixl_agent_config is None:
478+
config = None
479+
else:
480+
config = nixl_agent_config(backends=self.nixl_backends) if len(
481+
non_ucx_backends) > 0 else nixl_agent_config(num_threads=8)
479482

480483
self.nixl_wrapper = NixlWrapper(str(uuid.uuid4()), config)
481484
# Map of engine_id -> {rank0: agent_name0, rank1: agent_name1..}.

vllm/v1/core/sched/scheduler.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1288,4 +1288,9 @@ def _update_from_kv_xfer_finished(self,
12881288
self.finished_recving_kv_req_ids.add(req_id)
12891289
for req_id in (kv_connector_output.finished_sending or ()):
12901290
logger.debug("Finished sending KV transfer for request %s", req_id)
1291-
self._free_blocks(self.requests[req_id])
1291+
if req_id not in self.requests:
1292+
logger.warning(
1293+
"Got finished sending KV transfer for request %s,"
1294+
"but the request is already freed.", req_id)
1295+
else:
1296+
self._free_blocks(self.requests[req_id])

0 commit comments

Comments
 (0)