Skip to content

Conversation

WeldonWangwang
Copy link
Contributor

@WeldonWangwang WeldonWangwang commented May 19, 2025

@github-actions github-actions bot added the category: continuous batching Continuous batching label May 19, 2025
@as-suvorov as-suvorov requested a review from popovaan May 20, 2025 12:35
@Wovchena Wovchena requested a review from Copilot June 18, 2025 14:58
Copilot

This comment was marked as outdated.

@WeldonWangwang WeldonWangwang requested a review from Copilot June 19, 2025 06:08
Copilot

This comment was marked as outdated.

@Wovchena Wovchena requested a review from Copilot June 19, 2025 07:09
Copilot

This comment was marked as outdated.

@WeldonWangwang
Copy link
Contributor Author

WeldonWangwang commented Jun 20, 2025

Hi @Wovchena , I check the failed test case in CI with openvino-genai 2025.2.0.0 locally, some cases failed too, for example:
test_cb_streamer_vs_return_vs_stateful in https://github.com/openvinotoolkit/openvino.genai/actions/runs/15752272348/job/44400676499?pr=2227

image

Can you help to check if the CI works well? thanks!!!

@Wovchena
Copy link
Collaborator

CI is broken. I don't know the component to blame yet

@Wovchena Wovchena added this pull request to the merge queue Jun 20, 2025
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Jun 20, 2025
@WeldonWangwang
Copy link
Contributor Author

Hi @Wovchena , i re-run the failed item in merge queue, but it seems can not be merged again after failed.

@Wovchena Wovchena requested a review from Copilot June 23, 2025 06:57
Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR extends continuous batching to support multi-GPU execution by updating device assertions and block sizing logic.

  • Relax the assertion to allow single CPU, single GPU, or multiple GPUs.
  • Introduce all_gpu_device to drive block size and context initialization.
  • Replace per-GPU flag with all_gpu_device checks in cache manager.

Reviewed Changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.

File Description
src/cpp/src/continuous_batching/pipeline_impl.cpp Relax device assertion for heterogeneous pipelines and detect all-GPU deployments.
src/cpp/src/continuous_batching/cache_manager.hpp Use all_gpu_device for block size selection and context setup, replacing is_gpu logic.
Comments suppressed due to low confidence (1)

src/cpp/src/continuous_batching/pipeline_impl.cpp:107

  • [nitpick] Consider renaming all_gpu_device to all_gpu_devices to better reflect that it checks a collection of devices.
    const bool all_gpu_device =

std::all_of(execution_devices.begin(), execution_devices.end(), [&](const std::string& device) {
return device.find("GPU") != std::string::npos;
});
OPENVINO_ASSERT(all_gpu_device || execution_devices.size() == 1,
Copy link
Preview

Copilot AI Jun 23, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The assertion allows empty execution_devices (since all_of on an empty vector is true). Add a check to ensure execution_devices is non-empty before accessing index 0.

Copilot uses AI. Check for mistakes.

std::all_of(execution_devices.begin(), execution_devices.end(), [&](const std::string& device) {
return device.find("GPU") != std::string::npos;
});
OPENVINO_ASSERT(all_gpu_device || execution_devices.size() == 1,
Copy link
Preview

Copilot AI Jun 23, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As above, all_gpu_device will be true for an empty vector. Ensure execution_devices is not empty before using element 0 or combine this into the assertion.

Copilot uses AI. Check for mistakes.

@Wovchena Wovchena added this pull request to the merge queue Jun 23, 2025
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Jun 23, 2025
@Wovchena Wovchena added this pull request to the merge queue Jun 23, 2025
Merged via the queue into openvinotoolkit:master with commit 11401c1 Jun 23, 2025
149 of 160 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants