Skip to content

Fix: compile host_build_graph orchestration with host g++#1330

Merged
ChaoWao merged 1 commit into
mainfrom
fix/hbg-orch-host-gxx
Jul 11, 2026
Merged

Fix: compile host_build_graph orchestration with host g++#1330
ChaoWao merged 1 commit into
mainfrom
fix/hbg-orch-host-gxx

Conversation

@ChaoWao

@ChaoWao ChaoWao commented Jul 11, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • host_build_graph dlopens the orchestration .so on the x86_64 host, but compile_orchestration routed a2a3/a5 to the aarch64 cross-compiler unconditionally — that routing predates host_build_graph. The AArch64 orch .so could not be dlopened by the x86_64 host runtime, surfacing as dlopen failed: ... No such file or directory and failing every host_build_graph scene test on a2a3 onboard.
  • Route the orch toolchain by runtime instead of only by platform: host_build_graphHOST_GXX (host-dlopen path, onboard + sim); tensormap_and_ringbufferAARCH64_GXX onboard (AICPU dlopen), HOST_GXX for sim.
  • The else branch is byte-identical to before, so tensormap_and_ringbuffer is unchanged.

Root cause (evidence)

  • Before: orch .so (a2a3 host_build_graph) was Machine: AArch64; libhost_runtime.so and the host are X86-64. ldd reported "not a dynamic executable"; glibc's loader emits the misleading No such file or directory on an ELF machine mismatch.
  • After: orch .so is X86-64, ldd resolves all deps cleanly.

Testing

Onboard a2a3 (910B2C), device 0 (run unlocked — task-submit is not on this box; results are deterministic, not concurrency-related):

Test Before After
host_build_graph/vector_example ❌ dlopen fail ✅ PASSED
host_build_graph/paged_attention (the case #1185 claimed passed) ❌ dlopen fail ✅ PASSED
tensormap_and_ringbuffer/alternating_matmul_add (regression guard) ✅ PASSED

Note

a5 host_build_graph takes the same code path (also host-dlopen) and is fixed by this change, but I have no a5 silicon here to onboard-verify — please run an a5 host_build_graph case on an a5 box / the a5 CI leg.

@coderabbitai

coderabbitai Bot commented Jul 11, 2026

Copy link
Copy Markdown

Warning

Review limit reached

@ChaoWao, you've reached your PR review limit, so we couldn't start this review.

Next review available in: 42 minutes

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: c5349f8a-e100-462d-a44f-f1c76d686bb4

📥 Commits

Reviewing files that changed from the base of the PR and between 7626f96 and c22d5e8.

📒 Files selected for processing (1)
  • simpler_setup/kernel_compiler.py

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

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

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

Copy link
Copy Markdown

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 updates the orchestration compilation logic in simpler_setup/kernel_compiler.py to use the host toolchain when the runtime is 'host_build_graph'. Feedback on this change points out that the implementation silently falls back to the cross-compilation toolchain for any other runtime name, which violates the function's docstring stating that an unknown runtime name should raise a ValueError. It is recommended to explicitly validate the runtime name and raise an error if it is unsupported.

Important

The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.

Comment thread simpler_setup/kernel_compiler.py
@ChaoWao ChaoWao force-pushed the fix/hbg-orch-host-gxx branch from 35f3281 to c22d5e8 Compare July 11, 2026 11:00
host_build_graph dlopens the orchestration .so on the x86_64 host, but
compile_orchestration routed a2a3/a5 to the aarch64 cross-compiler
unconditionally — that routing predates host_build_graph. The AArch64
orch .so could not be dlopened by the x86_64 host runtime, surfacing as
"dlopen failed: ... No such file or directory" and failing every
host_build_graph scene test on a2a3 onboard.

Route the orch toolchain by runtime instead of only by platform:
host_build_graph uses HOST_GXX (the host-dlopen path, onboard and sim);
tensormap_and_ringbuffer keeps AARCH64_GXX onboard (AICPU dlopen) and
HOST_GXX for sim. Unknown runtime_name now raises ValueError, matching
the docstring's documented contract.

Verified on a2a3 onboard (910B2C): host_build_graph vector_example and
paged_attention now pass; tensormap alternating_matmul_add unchanged
(regression guard). a5 host_build_graph takes the same path but has no
a5 silicon here to onboard-verify.
@ChaoWao ChaoWao merged commit a377067 into main Jul 11, 2026
16 checks passed
@ChaoWao ChaoWao deleted the fix/hbg-orch-host-gxx branch July 11, 2026 11:50
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