Skip to content

refactor(rlix-validation): read model_update_transport once#26

Open
TianyeGGBond wants to merge 1 commit into
rlops:zhenyu/m11-mvp-testfrom
TianyeGGBond:tianye/f10-dedupe-transport-read
Open

refactor(rlix-validation): read model_update_transport once#26
TianyeGGBond wants to merge 1 commit into
rlops:zhenyu/m11-mvp-testfrom
TianyeGGBond:tianye/f10-dedupe-transport-read

Conversation

@TianyeGGBond

Copy link
Copy Markdown

Context

assert_rlix_topology reads args.model_update_transport in two places:

  • C11 (inside if is_rlix_mode():) to enforce cpu_serialize in RLix mode
  • S2 to decide has_gpu_staging (whether a GPU-staging transport is in play)
# C11
if is_rlix_mode():
    transport = getattr(args, "model_update_transport", "cuda_ipc")
    ...
# S2
transport = getattr(args, "model_update_transport", "cuda_ipc")
has_gpu_staging = _topology_has_non_colocate_engines(args) or transport == "cuda_ipc"

The C11 copy is scoped inside the is_rlix_mode() branch, so S2 can't reuse it and re-reads the same arg with the same default.

Change

Fetch transport once in the top-of-function derived block (alongside train, infer, engine_count, per_engine) and drop both local re-reads. Single source, no behavioral change.

🤖 Generated with Claude Code

`transport` was fetched twice inside assert_rlix_topology (C11 and S2) from
the same arg. Hoist it into the top-of-function derived block so there is a
single source.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
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