Skip to content

[Common] Default EP comm kernels to 32 SMs; keep shuffle/preprocess on all SMs - #3422

Open
phu0ngng wants to merge 1 commit into
NVIDIA:mainfrom
phu0ngng:ep-sm-defaults
Open

[Common] Default EP comm kernels to 32 SMs; keep shuffle/preprocess on all SMs#3422
phu0ngng wants to merge 1 commit into
NVIDIA:mainfrom
phu0ngng:ep-sm-defaults

Conversation

@phu0ngng

Copy link
Copy Markdown
Collaborator

Description

Set a sane default SM budget for EP dispatch/combine (32 SMs) while leaving the local shuffle/preprocess kernels on all device SMs.

Type of change

  • Documentation change (change only to the documentation, either a fix or a new content)
  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Infra/Build change
  • Code refactoring

Checklist:

  • I have read and followed the contributing guidelines
  • The functionality is complete
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes

…s on all SMs

Signed-off-by: Phuong Nguyen <phuonguyen@nvidia.com>
@phu0ngng

Copy link
Copy Markdown
Collaborator Author

/te-ci L1

@greptile-apps

greptile-apps Bot commented Aug 25, 2026

Copy link
Copy Markdown
Contributor

Greptile Summary

The PR changes the default NCCL EP dispatch/combine budget from automatic sizing to 32 SMs, clamped to the active device, while defaulting local shuffle and preprocessing kernels to all device SMs.

  • Updates the native EP group configuration and process environment defaults.
  • Updates the public C and JAX documentation for the new communication-kernel default.
  • Leaves one native validation diagnostic using the old zero-means-auto terminology.

Confidence Score: 4/5

The PR appears safe to merge, with one non-blocking diagnostic inconsistency that should be corrected.

The implementation and public API documentation consistently apply the new 32-SM default, but invalid native configurations can still produce an error message claiming that zero enables automatic sizing.

Files Needing Attention: transformer_engine/common/ep/ep_backend.cpp

Important Files Changed

Filename Overview
transformer_engine/common/ep/ep_backend.cpp Implements the new SM defaults correctly at initialization, but leaves the validation message describing the former zero-value semantics.
transformer_engine/common/include/transformer_engine/ep.h Updates the public native configuration documentation to describe the 32-SM clamped default.
transformer_engine/jax/ep.py Updates the JAX API documentation consistently with the new dispatch/combine default.

Reviews (1): Last reviewed commit: "[Common] Default EP comm kernels to 32 S..." | Re-trigger Greptile

Comment on lines 245 to +247
cfg.max_num_sms = group_config.num_comm_sms > 0
? static_cast<unsigned int>(group_config.num_comm_sms)
: NCCL_EP_AUTO;
: static_cast<unsigned int>(std::min(kDefaultCommSms, device_sms));

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.

P2 Stale zero-budget diagnostic

The implementation now maps num_comm_sms == 0 to min(32, device_sms), but the native validation message still describes zero as automatic sizing, misleading users who are diagnosing or selecting the communication-kernel SM budget.

Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!

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.

1 participant