Skip to content

[None][feat] Upgrade NIXL to v1.0.1 and UCX to v1.21.x - #14056

Open
nv-anants wants to merge 3 commits into
NVIDIA:mainfrom
nv-anants:upgrade/nixl-v1.0.1-ucx-v1.21
Open

[None][feat] Upgrade NIXL to v1.0.1 and UCX to v1.21.x#14056
nv-anants wants to merge 3 commits into
NVIDIA:mainfrom
nv-anants:upgrade/nixl-v1.0.1-ucx-v1.21

Conversation

@nv-anants

@nv-anants nv-anants commented May 12, 2026

Copy link
Copy Markdown

Bump NIXL from 0.9.0 to v1.0.1 (requires UCX 1.21.x) and UCX from v1.20.x to v1.21.x in the dev container.

After installing UCX 1.21 to /usr/local/ucx, replace any pre-existing HPC-X UCX directory shipped in the NGC PyTorch base image (/opt/hpcx*/ucx) with a symlink to /usr/local/ucx and refresh the system linker cache. This ensures PyTorch/NCCL/UCC and the NIXL stack resolve the same single UCX 1.21 binary, fixing the dual-UCX-load failure (mix of UCX 1.20 and 1.21 in the same process) that prevented the NIXL UCX backend from initializing in disagg tests.

Update the matching test fixtures: switch test_agent.py to the string "VRAM" memory_type (NIXL 1.0.1 rebinds MemoryType to a C++ enum at runtime, so direct enum comparison no longer matches the strings flowing through RegMemoryDescs), and pass is_disagg=True to create_hybrid_cache_manager in test_kv_cache_transceiver.py.

Summary by CodeRabbit

  • Chores

    • Updated NIXL to version 1.0.1.
    • Updated UCX to version 1.21.x with enhanced linker configuration.
    • Updated development dependencies.
  • Tests

    • Improved test infrastructure for memory allocation and cache management operations.

Review Change Stack

@nv-anants
nv-anants requested a review from a team May 12, 2026 22:40
@nv-anants
nv-anants requested review from a team as code owners May 12, 2026 22:40
@nv-anants
nv-anants requested review from tburt-nv and yuanjingx87 May 12, 2026 22:40
@coderabbitai

coderabbitai Bot commented May 12, 2026

Copy link
Copy Markdown
Contributor
📝 Walkthrough

Walkthrough

This PR upgrades NIXL (0.9.0 → v1.0.1) and UCX (v1.20.x → v1.21.x) build tools across Docker scripts and development dependencies. UCX installation now includes symlink setup and dynamic linker registration. Test memory allocation helpers transition to string-based memory types, and hybrid cache managers are configured for disaggregated mode.

Changes

Build tooling and disaggregated memory test support

Layer / File(s) Summary
NIXL version upgrade to v1.0.1
docker/common/install_nixl.sh, requirements-dev.txt
NIXL build tool is bumped from 0.9.0 to v1.0.1 in both the Docker installation script and Python development dependencies.
UCX version upgrade and container linker configuration
docker/common/install_ucx.sh
UCX is upgraded from v1.20.x to v1.21.x with pinned commit 167a4c6a. Post-install setup replaces pre-existing UCX directories with symlinks pointing to the new installation and registers the UCX lib path with the system dynamic linker via /etc/ld.so.conf.d/ucx.conf and ldconfig.
Disaggregated memory test helpers and cache manager configuration
tests/unittest/disaggregated/test_agent.py, tests/unittest/others/test_kv_cache_transceiver.py
MemoryManager.allocate_memory now accepts memory_type as a string (default "VRAM") instead of enum, with device selection comparing string values. MambaHybridCacheManager is configured with is_disagg=True flag in cache transceiver tests.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

🚥 Pre-merge checks | ✅ 3 | ❌ 2

❌ Failed checks (1 warning, 1 inconclusive)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 50.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
Description check ❓ Inconclusive The PR description addresses the why and what with clear context, but does not follow the required template structure with distinct Description, Test Coverage, and PR Checklist sections. Restructure the description to follow the template with separate Description, Test Coverage, and PR Checklist sections. Confirm test coverage for the updated memory_type handling and is_disagg parameter changes.
✅ Passed checks (3 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly and concisely summarizes the main changes: upgrading NIXL to v1.0.1 and UCX to v1.21.x, which are the primary objectives of the PR.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Comment @coderabbitai help to get the list of available commands and usage tips.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Actionable comments posted: 1

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (2)
tests/unittest/disaggregated/test_agent.py (1)

1-1: ⚠️ Potential issue | 🟠 Major | ⚡ Quick win

Add/update NVIDIA copyright header for this modified file.

Line 1 indicates this modified Python file is missing the required NVIDIA header/year update.

As per coding guidelines: “Include NVIDIA copyright header on all new files; update year on modified files.”

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@tests/unittest/disaggregated/test_agent.py` at line 1, Add or update the
required NVIDIA copyright header at the top of this modified file
(tests/unittest/disaggregated/test_agent.py) so the file includes the standard
header block with the current year and NVIDIA ownership; ensure the header
appears before any code (before the existing "from dataclasses import dataclass,
field" import) and matches the project's canonical header format used in other
files.
tests/unittest/others/test_kv_cache_transceiver.py (1)

1-1: ⚠️ Potential issue | 🟠 Major | ⚡ Quick win

Add/update NVIDIA copyright header for this modified file.

Line 1 shows this modified Python source file without the required NVIDIA header/year update.

As per coding guidelines: “All TensorRT-LLM source files (.cpp, .h, .cu, .py) must contain an NVIDIA copyright header with the year of latest meaningful modification.”

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@tests/unittest/others/test_kv_cache_transceiver.py` at line 1, The file
tests/unittest/others/test_kv_cache_transceiver.py is missing the required
NVIDIA copyright header/updated year; add the standard NVIDIA copyright comment
block at the top of test_kv_cache_transceiver.py (above the existing imports
like the "import time" line), updating the year to the latest meaningful
modification and matching the project's header format and wording used in other
.py files so the file complies with the repository's copyright/header
guidelines.
🧹 Nitpick comments (1)
tests/unittest/others/test_kv_cache_transceiver.py (1)

333-537: QA integration test-list updates are unnecessary for this PR scope.

This file change is limited to tests/unittest/**; no tests/integration/defs/** coverage matrix update is needed.

As per coding guidelines: “If the PR only touches unittest/ or narrow unit scope, say explicitly whether QA list updates are unnecessary or optional.”

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@tests/unittest/others/test_kv_cache_transceiver.py` around lines 333 - 537,
The PR only modifies unit tests under tests/unittest (not integration matrix),
so QA integration test-list updates are unnecessary; update the PR description
and commit message to explicitly state that QA list updates are not required for
this change and reference the modified tests (test_kybrid... — e.g.,
test_hybrid_cache_transceiver_single_process and
test_hybrid_cache_transceiver_cancel_request in test_kv_cache_transceiver.py) to
make the intent clear per the coding guideline. Ensure the PR description
contains the phrase that QA integration defs updates are unnecessary for this
unit-scope change.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@docker/common/install_ucx.sh`:
- Around line 37-42: The loop that iterates "for d in /opt/hpcx/ucx
/opt/hpcx-*/ucx; do" skips symlinks due to the "[ ! -L "$d" ]" check, leaving
stale symlinks pointing to old UCX; change the conditional to act on any
existing path (e.g., use "[ -e "$d" ]" only) or explicitly treat symlinks as
removable (e.g., "[ -e "$d" ] || [ -L "$d" ]" or just "[ -e "$d" ]" and then rm
-rf "$d"), then rm -rf "$d" and recreate the symlink to "${UCX_INSTALL_PATH%/}"
so both real dirs and symlinks are replaced; update the block containing the for
loop and UCX_INSTALL_PATH usage accordingly.

---

Outside diff comments:
In `@tests/unittest/disaggregated/test_agent.py`:
- Line 1: Add or update the required NVIDIA copyright header at the top of this
modified file (tests/unittest/disaggregated/test_agent.py) so the file includes
the standard header block with the current year and NVIDIA ownership; ensure the
header appears before any code (before the existing "from dataclasses import
dataclass, field" import) and matches the project's canonical header format used
in other files.

In `@tests/unittest/others/test_kv_cache_transceiver.py`:
- Line 1: The file tests/unittest/others/test_kv_cache_transceiver.py is missing
the required NVIDIA copyright header/updated year; add the standard NVIDIA
copyright comment block at the top of test_kv_cache_transceiver.py (above the
existing imports like the "import time" line), updating the year to the latest
meaningful modification and matching the project's header format and wording
used in other .py files so the file complies with the repository's
copyright/header guidelines.

---

Nitpick comments:
In `@tests/unittest/others/test_kv_cache_transceiver.py`:
- Around line 333-537: The PR only modifies unit tests under tests/unittest (not
integration matrix), so QA integration test-list updates are unnecessary; update
the PR description and commit message to explicitly state that QA list updates
are not required for this change and reference the modified tests
(test_kybrid... — e.g., test_hybrid_cache_transceiver_single_process and
test_hybrid_cache_transceiver_cancel_request in test_kv_cache_transceiver.py) to
make the intent clear per the coding guideline. Ensure the PR description
contains the phrase that QA integration defs updates are unnecessary for this
unit-scope change.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Enterprise

Run ID: 82fbdb43-18f7-47d8-b049-1b699c2fdc60

📥 Commits

Reviewing files that changed from the base of the PR and between 113bc64 and 9c6aa09.

📒 Files selected for processing (5)
  • docker/common/install_nixl.sh
  • docker/common/install_ucx.sh
  • requirements-dev.txt
  • tests/unittest/disaggregated/test_agent.py
  • tests/unittest/others/test_kv_cache_transceiver.py

Comment thread docker/common/install_ucx.sh
@nv-yna

nv-yna commented May 12, 2026

Copy link
Copy Markdown
Collaborator

/bot run --disable-fail-fast

@nv-yna

nv-yna commented May 12, 2026

Copy link
Copy Markdown
Collaborator

/bot run --add-multi-gpu-test --disable-fail-fast

@tensorrt-cicd

Copy link
Copy Markdown
Collaborator

PR_Github #48038 [ run ] triggered by Bot. Commit: 0a80d21 Link to invocation

@tensorrt-cicd

Copy link
Copy Markdown
Collaborator

PR_Github #48039 [ run ] triggered by Bot. Commit: 0a80d21 Link to invocation

@svc-trtllm-gh-bot svc-trtllm-gh-bot added the Community want to contribute PRs initiated from Community label May 12, 2026
@nv-yna

nv-yna commented May 12, 2026

Copy link
Copy Markdown
Collaborator

/bot run --add-multi-gpu-test --disable-fail-fast

@tensorrt-cicd

Copy link
Copy Markdown
Collaborator

PR_Github #48049 [ run ] triggered by Bot. Commit: 58a3f20 Link to invocation

@Shixiaowei02

Copy link
Copy Markdown
Collaborator

@nv-anants This PR does not update the Docker image links, so the test results may not be valid.

@nv-anants

Copy link
Copy Markdown
Author

@nv-anants This PR does not update the Docker image links, so the test results may not be valid.

Thanks for letting me know @Shixiaowei02. What should i update the docker image links to?

@Shixiaowei02

Copy link
Copy Markdown
Collaborator

@nv-anants This PR does not update the Docker image links, so the test results may not be valid.

Thanks for letting me know @Shixiaowei02. What should i update the docker image links to?

Steps

  1. Trigger an image build on this PR: /bot run --stage-list "Build-Docker-Images"
  2. Once the pipeline is green, note the source branch and build id.
  3. Run the rename script to retag/push the images and update the properties file in place: python scripts/rename_docker_images.py ...
  4. Commit the updated jenkins/current_image_tags.properties and /bot run again for full CI.
    See docker/README.md → "Building CI images" for details.

@tensorrt-cicd

Copy link
Copy Markdown
Collaborator

PR_Github #48049 [ run ] completed with state SUCCESS. Commit: 58a3f20
/LLM/main/L0_MergeRequest_PR pipeline #37883 completed with status: 'FAILURE'

CI Report

⚠️ Action Required:

  • Please check the failed tests and fix your PR
  • If you cannot view the failures, ask the CI triggerer to share details
  • Once fixed, request an NVIDIA team member to trigger CI again

CI Agent Failure Analysis

Link to invocation

nv-anants added 3 commits May 13, 2026 14:40
Bump NIXL from 0.9.0 to v1.0.1 (requires UCX 1.21.x) and UCX from
v1.20.x to v1.21.x in the dev container.

After installing UCX 1.21 to /usr/local/ucx, replace any pre-existing
HPC-X UCX directory shipped in the NGC PyTorch base image
(/opt/hpcx*/ucx) with a symlink to /usr/local/ucx and refresh the
system linker cache. This ensures PyTorch/NCCL/UCC and the NIXL stack
resolve the same single UCX 1.21 binary, fixing the dual-UCX-load
failure (mix of UCX 1.20 and 1.21 in the same process) that prevented
the NIXL UCX backend from initializing in disagg tests.

Update the matching test fixtures: switch test_agent.py to the string
"VRAM" memory_type (NIXL 1.0.1 rebinds MemoryType to a C++ enum at
runtime, so direct enum comparison no longer matches the strings
flowing through RegMemoryDescs), and pass is_disagg=True to
create_hybrid_cache_manager in test_kv_cache_transceiver.py.

Signed-off-by: Anant Sharma <anants@nvidia.com>
Change the conditional in the /opt/hpcx*/ucx replacement loop from
`[ -e "$d" ] && [ ! -L "$d" ]` to `[ -e "$d" ] || [ -L "$d" ]` so the
script also overwrites stale or broken symlinks at $d, not just real
directories. The previous condition skipped any symlink, which would
leave a pre-existing symlink to an old UCX in place. The new check is
idempotent: re-running the script over our own symlink simply
recreates an identical symlink.

Signed-off-by: Anant Sharma <anants@nvidia.com>
…its symlink

Change `rm -rf ${UCX_INSTALL_PATH}` (with trailing slash) to
`rm -rf "${UCX_INSTALL_PATH%/}"`. The NGC PyTorch base image ships
/usr/local/ucx as a symlink to /opt/hpcx/ucx; with the trailing
slash, rm followed the symlink and only emptied its target, leaving
the symlink intact. `make install --prefix=/usr/local/ucx/` then
wrote UCX 1.21 *through* the symlink into /opt/hpcx/ucx, and the
subsequent /opt/hpcx/ucx -> /usr/local/ucx replacement created an
infinite symlink loop, breaking the NIXL UCX-plugin compile with
"Too many levels of symbolic links".

Without the trailing slash, rm removes the symlink itself, `make
install` creates a fresh real directory at /usr/local/ucx, and the
HPC-X path is symlinked one-way to it. Verified in the rebuilt
dev container: only one physical UCX install, torch and the NIXL
UCX backend share /usr/local/ucx in the same process.

Signed-off-by: Anant Sharma <anants@nvidia.com>
@Shixiaowei02
Shixiaowei02 force-pushed the upgrade/nixl-v1.0.1-ucx-v1.21 branch from 58a3f20 to 0d8502a Compare May 13, 2026 06:40
@Shixiaowei02

Copy link
Copy Markdown
Collaborator

/bot run --stage-list "Build-Docker-Images"

@tensorrt-cicd

Copy link
Copy Markdown
Collaborator

PR_Github #48121 [ run ] triggered by Bot. Commit: 0d8502a Link to invocation

zackyoray added a commit to zackyoray/TensorRT-LLM that referenced this pull request May 13, 2026
Cherry-picked from PR NVIDIA#14056. Two related fixes to docker/common/install_ucx.sh:

- Strip the trailing slash before `rm -rf "${UCX_INSTALL_PATH%/}"` so
  that a pre-existing symlink at /usr/local/ucx (NGC PyTorch ships it
  as a symlink to /opt/hpcx/ucx) is removed instead of being followed.
- After `make install`, replace any pre-existing UCX under
  /opt/hpcx/ucx and /opt/hpcx-*/ucx with a symlink to the freshly
  installed /usr/local/ucx, and register /usr/local/ucx/lib with the
  dynamic linker via /etc/ld.so.conf.d/ucx.conf + ldconfig, so all
  binaries in the container resolve the same UCX SONAMEs.

Signed-off-by: Yoray Zack <62789610+zackyoray@users.noreply.github.com>
@tensorrt-cicd

Copy link
Copy Markdown
Collaborator

PR_Github #48121 [ run ] completed with state FAILURE. Commit: 0d8502a
/LLM/main/L0_MergeRequest_PR pipeline #37948 (Partly Tested) completed with status: 'FAILURE'

CI Report

⚠️ Action Required:

  • Please check the failed tests and fix your PR
  • If you cannot view the failures, ask the CI triggerer to share details
  • Once fixed, request an NVIDIA team member to trigger CI again

CI Agent Failure Analysis

Link to invocation

@nv-yna

nv-yna commented May 14, 2026

Copy link
Copy Markdown
Collaborator

/bot run --stage-list "Build-Docker-Images"

@tensorrt-cicd

Copy link
Copy Markdown
Collaborator

PR_Github #48296 [ run ] triggered by Bot. Commit: 0d8502a Link to invocation

@tensorrt-cicd

Copy link
Copy Markdown
Collaborator

PR_Github #48296 [ run ] completed with state FAILURE. Commit: 0d8502a
/LLM/main/L0_MergeRequest_PR pipeline #38108 (Partly Tested) completed with status: 'FAILURE'

CI Report

⚠️ Action Required:

  • Please check the failed tests and fix your PR
  • If you cannot view the failures, ask the CI triggerer to share details
  • Once fixed, request an NVIDIA team member to trigger CI again

CI Agent Failure Analysis

Link to invocation

zackyoray added a commit to zackyoray/TensorRT-LLM that referenced this pull request May 19, 2026
Cherry-picked from PR NVIDIA#14056. Two related fixes to docker/common/install_ucx.sh:

- Strip the trailing slash before `rm -rf "${UCX_INSTALL_PATH%/}"` so
  that a pre-existing symlink at /usr/local/ucx (NGC PyTorch ships it
  as a symlink to /opt/hpcx/ucx) is removed instead of being followed.
- After `make install`, replace any pre-existing UCX under
  /opt/hpcx/ucx and /opt/hpcx-*/ucx with a symlink to the freshly
  installed /usr/local/ucx, and register /usr/local/ucx/lib with the
  dynamic linker via /etc/ld.so.conf.d/ucx.conf + ldconfig, so all
  binaries in the container resolve the same UCX SONAMEs.

Signed-off-by: Yoray Zack <62789610+zackyoray@users.noreply.github.com>
@karljang karljang removed the Community want to contribute PRs initiated from Community label Jun 11, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants