Skip to content

[NemotronH] Use ReplicatedLinear for fc1_latent_proj#31807

Merged
tlrmchlsmth merged 1 commit intovllm-project:mainfrom
roikoren755:feat/latent-in-replicated-linear
Jan 6, 2026
Merged

[NemotronH] Use ReplicatedLinear for fc1_latent_proj#31807
tlrmchlsmth merged 1 commit intovllm-project:mainfrom
roikoren755:feat/latent-in-replicated-linear

Conversation

@roikoren755
Copy link
Copy Markdown
Contributor

@roikoren755 roikoren755 commented Jan 6, 2026

Purpose

Current implementation of latent MoE uses a ColumnParallelLinear for the fc1_latent_proj layer. After profiling, the synchronization overhead is quite substantial, and given that the layer itself is relatively small, replicating it instead improves performance while not costing too much in terms of VRAM usage.

Test Plan

Test Result


Essential Elements of an Effective PR Description Checklist
  • The purpose of the PR, such as "Fix some issue (link existing issues this PR will resolve)".
  • The test plan, such as providing test command.
  • The test results, such as pasting the results comparison before and after, or e2e results
  • (Optional) The necessary documentation update, such as updating supported_models.md and examples for a new model.
  • (Optional) Release notes update. If your change is user facing, please update the release notes draft in the Google Doc.

Signed-off-by: Roi Koren <roik@nvidia.com>
Copy link
Copy Markdown
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request replaces ColumnParallelLinear with ReplicatedLinear for the fc1_latent_proj layer in the latent MoE implementation. As described, this is a sound performance optimization for a relatively small layer, trading a small increase in VRAM for a reduction in synchronization overhead. The code change is correct and well-contained. I approve this change.

@tlrmchlsmth tlrmchlsmth added the ready ONLY add when PR is ready to merge/full CI is needed label Jan 6, 2026
Copy link
Copy Markdown
Member

@tlrmchlsmth tlrmchlsmth left a comment

Choose a reason for hiding this comment

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

Anything you can share on the performance difference? Mainly just curious

@tlrmchlsmth tlrmchlsmth enabled auto-merge (squash) January 6, 2026 14:08
@tlrmchlsmth tlrmchlsmth merged commit 28c9477 into vllm-project:main Jan 6, 2026
56 checks passed
LucasWilkinson pushed a commit to neuralmagic/vllm that referenced this pull request Jan 6, 2026
@roikoren755 roikoren755 deleted the feat/latent-in-replicated-linear branch January 6, 2026 19:01
yugong333 pushed a commit to yugong333/vllm that referenced this pull request Jan 9, 2026
akh64bit pushed a commit to akh64bit/vllm that referenced this pull request Jan 16, 2026
dsuhinin pushed a commit to dsuhinin/vllm that referenced this pull request Jan 21, 2026
)

Signed-off-by: Roi Koren <roik@nvidia.com>
Signed-off-by: dsuhinin <suhinin.dmitriy@gmail.com>
ItzDEXX pushed a commit to ItzDEXX/vllm that referenced this pull request Feb 19, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ready ONLY add when PR is ready to merge/full CI is needed

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants