fix: NCCL group auto-resolve crash on load + Infinity SymInt in extract_var_range_info - #4428
Merged
Merged
Conversation
apbose
force-pushed
the
abose/torchTRT_export_example_load_fix
branch
from
July 23, 2026 00:48
d3b3f84 to
4c90ef6
Compare
apbose
force-pushed
the
abose/torchTRT_export_example_load_fix
branch
from
July 23, 2026 00:52
4c90ef6 to
09956c0
Compare
There was a problem hiding this comment.
There are some changes that do not conform to C++ style guidelines:
diff --git a/home/runner/work/TensorRT/TensorRT/core/runtime/TRTEngine.cpp b/tmp/changes.txt
index 3b1b52a..4270d84 100644
--- a/home/runner/work/TensorRT/TensorRT/core/runtime/TRTEngine.cpp
+++ b/tmp/changes.txt
@@ -592,7 +592,8 @@ bool TRTEngine::bind_nccl_comm() {
std::vector<std::string> nccl_groups;
for (int i = 0; i < 20; ++i) {
auto pg = try_resolve(std::to_string(i));
- if (!pg) break;
+ if (!pg)
+ break;
if (pg->getBackendType() == c10d::ProcessGroup::BackendType::NCCL) {
nccl_groups.push_back(std::to_string(i));
}
ERROR: Some files do not conform to style guidelines
apbose
force-pushed
the
abose/torchTRT_export_example_load_fix
branch
from
July 23, 2026 00:57
09956c0 to
ca1cb51
Compare
There was a problem hiding this comment.
There are some changes that do not conform to C++ style guidelines:
diff --git a/home/runner/work/TensorRT/TensorRT/core/runtime/TRTEngine.cpp b/tmp/changes.txt
index 7216be6..4f44c36 100644
--- a/home/runner/work/TensorRT/TensorRT/core/runtime/TRTEngine.cpp
+++ b/tmp/changes.txt
@@ -592,7 +592,8 @@ bool TRTEngine::bind_nccl_comm() {
std::vector<std::string> nccl_groups;
for (int i = 0; i < 20; ++i) {
auto pg = try_resolve(std::to_string(i));
- if (!pg) break;
+ if (!pg)
+ break;
if (pg->getBackendType() == c10d::ProcessGroup::BackendType::NCCL) {
nccl_groups.push_back(std::to_string(i));
}
ERROR: Some files do not conform to style guidelines
apbose
force-pushed
the
abose/torchTRT_export_example_load_fix
branch
from
July 23, 2026 01:03
ca1cb51 to
283f7bd
Compare
…ct_var_range_info
TRTEngine.cpp — bind_nccl_comm auto-resolve:
PyTorch >= 2.14 throws c10::Error when resolve_process_group() is called
with a name that doesn't exist, instead of returning nullptr. The sequential
probe loop (0..19) would crash at i=1 on a fresh load-only process that only
has WORLD registered as "0". Replace the bare call with a try_resolve lambda
that normalises the throw to nullptr so the scan loop stays exception-free.
dynamo/utils.py — extract_var_range_info:
bound_sympy() returns sympy.oo for unbounded composite exprs (e.g. -s56),
which is distinct from int_oo. int(sympy.oo) raises AttributeError
('Infinity' object has no attribute '_mpf_'). Add _bound_to_int_or_none
helper that guards both int_oo and sympy.oo cases and catches
TypeError/OverflowError/AttributeError so unbounded dims fall back to 1.
7 tasks
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Description
Please include a summary of the change and which issue is fixed. Please also include relevant motivation and context. List any dependencies that are required for this change.
Fixes # (issue)
Type of change
Please delete options that are not relevant and/or add your own.
Checklist: