Repository navigation
[None][perf] use native protobuf and streamline gRPC result delivery #19760
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
jthomson04
merged 19 commits into
NVIDIA:main
from
jthomson04:jthomson04/grpc-native-protobuf
Oct 26, 2026
Merged
Changes from 13 commits
Commits
Show all changes
19 commits
Select commit
Hold shift + click to select a range
5d67471
[None][perf] use native protobuf and avoid SMG token-history copies
jthomson04 96e2824
[None][perf] preserve protobuf compatibility and cover gRPC fixes
jthomson04 6237314
Merge current main for the gRPC performance comparison
jthomson04 88f331b
perf: use callbacks for frontend result notifications
jthomson04 2b34042
fix: keep protobuf backend warnings optional
jthomson04 b299e8b
Merge remote-tracking branch 'origin/main' into jthomson04/grpc-proto…
jthomson04 7d1f3a8
[None][infra] Use CI images built with native protobuf
jthomson04 8225e39
[None][test] Isolate protobuf backend patch in gRPC startup test
jthomson04 6a879ff
Merge remote-tracking branch 'origin/main' into jthomson04/grpc-proto…
jthomson04 3b1f4b8
Merge remote-tracking branch 'origin/main' into jthomson04/grpc-proto…
jthomson04 7200aa8
[None][infra] Use CI images rebuilt with native protobuf on current main
jthomson04 abf1631
fix(ci): resolve image-tag conflict with main
tanmayv25 7166068
Merge remote-tracking branch 'origin/main' into jthomson04/grpc-proto…
jthomson04 802253e
[None][infra] Use CI images rebuilt with native protobuf on current main
jthomson04 c1ede4d
[None][test] Check only backend and model in gRPC startup test
jthomson04 333723f
Merge remote-tracking branch 'origin/main' into jthomson04/grpc-proto…
jthomson04 1c2e818
[None][test] Apply ruff-format to gRPC startup test
jthomson04 4b9fb03
[None][infra] Use CI images rebuilt with native protobuf on current main
jthomson04 f09845e
chore: use promoted CI images for PR 19760
chzblych File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,25 @@ | ||
| # SPDX-FileCopyrightText: Copyright (c) 2026 NVIDIA CORPORATION & AFFILIATES. All rights reserved. | ||
| # SPDX-License-Identifier: Apache-2.0 | ||
|
|
||
| """Protobuf performance guidance shared by the gRPC launchers.""" | ||
|
|
||
| from tensorrt_llm.logger import logger | ||
|
|
||
|
|
||
| def _warn_if_python_protobuf() -> None: | ||
| """Warn for Python protobuf if its implementation can be detected.""" | ||
| try: | ||
| from google.protobuf.internal import api_implementation | ||
|
|
||
| implementation = api_implementation.Type() | ||
| except (ImportError, AttributeError): | ||
| return | ||
|
|
||
| if implementation == "python": | ||
| logger.warning( | ||
| "TensorRT-LLM gRPC is using Python protobuf, which can reduce throughput. Set " | ||
| "PROTOCOL_BUFFERS_PYTHON_IMPLEMENTATION=upb before starting Python " | ||
| "and install a supported protobuf wheel with the upb extension. " | ||
| "Changing the environment after importing protobuf does not change " | ||
| "the active implementation." | ||
| ) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.