Skip to content

UCT: DF LB infra to propagate SPEED_CHANGE events from UCT - #11032

Merged
brminich merged 14 commits into
openucx:masterfrom
iyastreb:ucx-dflow-lb-events
Dec 23, 2025
Merged

brminich merged 14 commits into
openucx:masterfrom
iyastreb:ucx-dflow-lb-events

Conversation

@iyastreb

@iyastreb iyastreb commented Dec 2, 2025 •

Copy link
Copy Markdown
Contributor

What?

This PR provides infrastructure to:

  • listen new type of IBV_EVENT_PORT_SPEED_CHANGE in UCT device
  • subscribe on this events using existing UCT iface API
  • propagate events to the upper layer

Why?

The initial implementation of the Dynamic Flow load balancer is based on detection IBV_EVENT_PORT_SPEED_CHANGE events and handling them on the upper layer by reading estimate_perf of the changed iface (will use ibv_query_port_speed for BW estimation in next PR).

How?

  • Rely on existing iface infra for async event callbacks
  • Tiny change in UCT API to register a new type of event
  • Pass this new type of event in the async callback flags (was reserved for future use)
  • Extend IB device async map to handle multiple events per entry (because multiple ifaces may subscribe for the same device event)

Test will be added in the subsequent PR (mock for IB event is needed)

@iyastreb iyastreb changed the title DFLOW/LB/UCT/UCP: Dynamic Flow Load balancer by IB events DFLOW/LB/UCT/UCP: Dynamic Flow IB events driven Load Balancer Dec 2, 2025
Comment thread src/uct/api/v2/uct_v2.h Resolved
Comment thread src/uct/api/v2/uct_v2.h Resolved
@iyastreb
iyastreb force-pushed the ucx-dflow-lb-events branch from 8a51305 to 38155c8 Compare December 2, 2025 10:25
Comment thread src/uct/api/uct_def.h Resolved
@iyastreb
iyastreb force-pushed the ucx-dflow-lb-events branch 2 times, most recently from f952f79 to 880a295 Compare December 2, 2025 16:24

@evgeny-leksikov evgeny-leksikov 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.

LGTM, pls update commit message and PR description

@iyastreb

iyastreb commented Dec 3, 2025

Copy link
Copy Markdown
Contributor Author

LGTM, pls update commit message and PR description

I plan to merge by larger pieces, for example when the entire event-propagation from UCT to UCP works.
Will convert to "Ready for review" once I have something

@iyastreb iyastreb changed the title DFLOW/LB/UCT/UCP: Dynamic Flow IB events driven Load Balancer UCT: DFlow LB infrastructure to propagate SPEED_CHANGE events from UCT to UCP Dec 4, 2025
@iyastreb iyastreb changed the title UCT: DFlow LB infrastructure to propagate SPEED_CHANGE events from UCT to UCP UCT: DFlow LB infra to propagate SPEED_CHANGE events from UCT to UCP Dec 4, 2025
@iyastreb iyastreb changed the title UCT: DFlow LB infra to propagate SPEED_CHANGE events from UCT to UCP UCT: DF LB infra to propagate SPEED_CHANGE events from UCT Dec 4, 2025
@iyastreb
iyastreb marked this pull request as ready for review December 4, 2025 15:51
@iyastreb
iyastreb force-pushed the ucx-dflow-lb-events branch from 1a7a76f to 124f72b Compare December 5, 2025 08:14
@iyastreb
iyastreb requested a review from yosefe December 5, 2025 09:13
Comment thread src/uct/api/uct.h Resolved
Comment thread src/ucp/core/ucp_worker.c Resolved
Comment thread src/uct/ib/base/ib_device.c Resolved
Comment thread src/uct/ib/base/ib_device.c Resolved
Comment thread src/uct/ib/base/ib_device.c Resolved
Comment thread src/uct/ib/base/ib_device.c Resolved
brminich
brminich previously approved these changes Dec 12, 2025
Comment thread src/ucp/core/ucp_worker.c Resolved
Comment thread src/uct/ib/base/ib_iface.c Resolved
@iyastreb
iyastreb force-pushed the ucx-dflow-lb-events branch from e4c8cbb to dc4b32c Compare December 17, 2025 12:42

@evgeny-leksikov evgeny-leksikov 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.

implementation looks good, design decicion how to specify EP is not clear to me.

Comment thread src/uct/ib/base/ib_iface.c Resolved
Comment thread src/uct/ib/base/ib_device.c Resolved
Comment thread src/ucp/core/ucp_worker.c Resolved
@brminich
brminich merged commit 4e100d4 into openucx:master Dec 23, 2025
jeynmann pushed a commit to jeynmann/ucx that referenced this pull request Jan 4, 2026
@iyastreb
iyastreb deleted the ucx-dflow-lb-events branch January 5, 2026 07:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants