Skip to content

Refactor: split per-device invariants into a one-shot AICPU init entry - #1201

Merged
ChaoWao merged 1 commit into
hw-native-sys:mainfrom
ChaoWao:refactor/aicpu-init-register-callable
Jun 30, 2026
Merged

ChaoWao merged 1 commit into
hw-native-sys:mainfrom
ChaoWao:refactor/aicpu-init-register-callable

Conversation

@ChaoWao

@ChaoWao ChaoWao commented Jun 30, 2026

Copy link
Copy Markdown
Collaborator

Summary

Per-device-fixed values rode on every per-task KernelArgs launch even
though they never change across runs. This lifts them into a single
worker-init-time AICPU entry and slims the callable-registration payload so it
no longer ships a full Runtime.

  • New InitArgs + simpler_aicpu_init — { device_id, log_level, log_info_v }
    launched once per device from ensure_device_initialized(). It latches these
    into the resident AICPU SO globals, so exec / register_callable no longer
    re-push them. The corresponding setters are removed from simpler_aicpu_exec
    and the fields dropped from KernelArgs. regs / pmu_reg_addrs / ffts
    stay per-run (a5 AICore still reads regs off the device KernelArgs copy).
  • prewarm → register_callable end to end —
    simpler_aicpu_prewarm_callable → simpler_aicpu_register_callable,
    aicpu_prewarm_callable → aicpu_register_callable, host prewarm_callable
    → aicpu_register_callable, KernelNames::PrewarmName →
    RegisterCallableName, plus new InitName.
  • New RegisterCallableArgs carrying only the orch-SO descriptor extracted
    from Runtime (callable id, dev SO addr/size, entry/config symbol names), so
    the register path no longer H2D's a full Runtime. ensure_orch_so_loaded
    is refactored into a core taking those values; the run-path Runtime*
    wrapper and the register entry both delegate to it.
  • Launch path generalized to void* + size so the three entries
    (exec / init / register_callable) share one mechanism; all three symbols are
    registered in the inner-SO JSON.
  • hbg variants are no-ops (host-side orchestration); the two missing
    dev_orch_so getters are added to hbg Runtime so the shared sim path
    compiles.

Testing

  • a2a3 + a5 build clean (onboard + sim, both runtimes), incl. post-clang-format
  • Simulation tests pass (a2a3sim + a5sim; register-path and exec-path, both runtimes)
  • Hardware tests pass — full a2a3 onboard sweep via task-submit: HBG 10 passed/2 skipped, TMARB 33 passed/1 skipped

@coderabbitai

coderabbitai Bot commented Jun 30, 2026 •

Copy link
Copy Markdown

Review Change Stack

Important

Review skipped

Auto incremental reviews are disabled on this repository.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 7eb27222-0614-4603-b899-ab9020954683

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
📝 Walkthrough

Walkthrough

Replaces the single simpler_aicpu_prewarm_callable AICPU entry point with two dedicated entries: simpler_aicpu_init (per-device one-shot, carries InitArgs) and simpler_aicpu_register_callable (per-callable, carries RegisterCallableArgs). Per-device invariants (device_id, log_level, log_info_v) are removed from KernelArgs and moved into InitArgs. The orchestration SO loader is refactored to accept explicit descriptor parameters without requiring a Runtime*. All host-side, sim-side, loader, and C API layers for both a2a3 and a5 targets are updated accordingly.

Changes

AICPU init + register_callable ABI refactor

Layer / File(s) Summary
KernelArgs ABI and kernel name constants
src/a2a3/platform/include/common/kernel_args.h, src/a5/platform/include/common/kernel_args.h, src/common/aicpu_loader/host/load_aicpu_op.h, src/common/aicpu_loader/host/load_aicpu_op.cpp
Adds INIT_ARGS_MAX_ORCH_SYMBOL_NAME; removes log_level, log_info_v, device_id from KernelArgs; introduces InitArgs and RegisterCallableArgs structs. KernelNames drops PrewarmName, adds InitName and RegisterCallableName. LaunchBuiltInOp and AicpuKernelLaunch generalized to void* + args_size.
On-device AICPU kernel entry points (a2a3 + a5)
src/a2a3/platform/onboard/aicpu/kernel.cpp, src/a5/platform/onboard/aicpu/kernel.cpp
Adds simpler_aicpu_init (latches log/device-id globals once per device) and simpler_aicpu_register_callable (delegates to aicpu_register_callable). Removes simpler_aicpu_prewarm_callable. simpler_aicpu_exec no longer sets per-device invariants each invocation.
tensormap_and_ringbuffer aicpu_executor: core SO loader + aicpu_register_callable (a2a3 + a5)
src/a2a3/runtime/tensormap_and_ringbuffer/aicpu/aicpu_executor.cpp, src/a5/runtime/tensormap_and_ringbuffer/aicpu/aicpu_executor.cpp, src/a2a3/runtime/host_build_graph/..., src/a5/runtime/host_build_graph/...
Introduces ensure_orch_so_loaded_core(...) taking explicit SO address/size and symbol-name params. aicpu_prewarm_callable replaced by aicpu_register_callable(const RegisterCallableArgs*). Host-build-graph stubs add get_dev_orch_so_addr/size getters. static_assert guards symbol-name capacity parity.
Host onboard DeviceRunnerBase: device init sequencing and aicpu_register_callable
src/common/platform/onboard/host/device_runner_base.h, src/common/platform/onboard/host/device_runner_base.cpp, src/common/platform/onboard/host/c_api_shared.cpp
ensure_device_initialized gains ensure_aicpu_init_launched after binaries load. aicpu_register_callable(int32_t) replaces prewarm_callable, building RegisterCallableArgs from CallableState and launching via new launch_aicpu_payload. init_runtime_args_with_metadata drops per-run log/device-id assignments. aicpu_init_launched_ guard added.
Sim DeviceRunner: invoke_aicpu_register_callable wiring (a2a3 + a5)
src/a2a3/platform/sim/host/device_runner.{h,cpp}, src/a5/platform/sim/host/device_runner.{h,cpp}, src/common/platform/sim/host/device_runner_base.{h,cpp}, src/common/platform/sim/host/c_api_shared.cpp
All sim layers replace invoke_aicpu_prewarm/prewarm_callable with invoke_aicpu_register_callable/aicpu_register_callable. dlsym loads aicpu_register_callable; RegisterCallableArgs is constructed from Runtime metadata before invocation.
Documentation updates
docs/aicpu-kernel-launch-mechanisms.md, docs/callable-identity-registration.md
Describes the new InitArgs/simpler_aicpu_init + simpler_aicpu_register_callable entry points and updated KernelArgs contract; updates Chip Executable Prewarm section to reference RegisterCallableArgs.

Sequence Diagram(s)

sequenceDiagram
  participant Host as DeviceRunnerBase (host)
  participant Loader as LoadAicpuOp
  participant AICPU as AICPU SO (device)
  participant Executor as AicpuExecutor

  rect rgba(70, 130, 180, 0.5)
    note over Host,AICPU: Device initialization (once per device)
    Host->>Loader: ensure_binaries_loaded()
    Host->>Loader: launch_aicpu_payload(InitArgs)
    Loader->>AICPU: simpler_aicpu_init(InitArgs)
    AICPU->>AICPU: latch device_id, log_level, log_info_v into globals
  end

  rect rgba(60, 179, 113, 0.5)
    note over Host,Executor: Callable registration (once per callable)
    Host->>Host: aicpu_register_callable(callable_id)
    Host->>Host: build RegisterCallableArgs from CallableState
    Host->>Loader: launch_aicpu_payload(RegisterCallableArgs)
    Loader->>AICPU: simpler_aicpu_register_callable(RegisterCallableArgs)
    AICPU->>Executor: aicpu_register_callable(RegisterCallableArgs)
    Executor->>Executor: ensure_orch_so_loaded_core(so_addr, so_size, symbols)
    Executor->>Executor: dlopen + dlsym → populate orch_so_table_[callable_id]
    Host->>Host: commit_aicpu_callable_load(callable_id)
  end

  rect rgba(255, 165, 0, 0.5)
    note over Host,AICPU: Per-task execution
    Host->>Loader: launch_aicpu_kernel(KernelArgs)
    Loader->>AICPU: simpler_aicpu_exec(KernelArgs)
    AICPU->>AICPU: set_platform_regs only (invariants already latched)
  end
Loading

Estimated code review effort

🎯 4 (Complex) | ⏱️ ~60 minutes

Possibly related PRs

  • hw-native-sys/simpler#928: Modifies the same src/common/platform/onboard/host/c_api_shared.cpp prepare_callable path that this PR updates to switch from prewarm_callable to aicpu_register_callable.
  • hw-native-sys/simpler#932: Introduces SimDeviceRunnerBase and the sim-side C API glue in src/common/platform/sim/host/device_runner_base.{h,cpp} that this PR renames from prewarm_callable/invoke_aicpu_prewarm to the new registration hooks.
  • hw-native-sys/simpler#1089: Deals with the AICPU callable orchestration SO materialization flow that this PR replaces with the simpler_aicpu_init + simpler_aicpu_register_callable two-phase mechanism.

Poem

🐇 Hoppity-hop, the prewarm is gone,
Two entries now carry the dawn:
init once latches the log and the id,
register_callable loads the SO inside.
Per-task KernelArgs stays lean and small—
The rabbit refactored it once, for all! 🎉

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 38.89% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly summarizes the main refactor: moving per-device invariants into a one-shot AICPU init entry.
Description check ✅ Passed The description accurately covers the AICPU init split, register-callable rename, payload changes, and launch-path refactor.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

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 refactors the AICPU kernel launch mechanism by separating per-device one-shot invariants into a new InitArgs structure initialized via simpler_aicpu_init, and replacing the old prewarm path with a more efficient simpler_aicpu_register_callable entry that uses a smaller RegisterCallableArgs payload. Feedback focuses on guarding against potential nullptr values passed to snprintf in the a2a3 and a5 device runners, and adding defensive validation checks for launch arguments in LoadAicpuOp::AicpuKernelLaunch.

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 src/a2a3/platform/sim/host/device_runner.cpp
Comment thread src/a5/platform/sim/host/device_runner.cpp
Comment thread src/common/aicpu_loader/host/load_aicpu_op.cpp

@coderabbitai coderabbitai 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.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@src/common/platform/onboard/host/device_runner_base.cpp`:
- Around line 358-388: The teardown path leaves the one-shot guard stale, so a
reused DeviceRunnerBase instance can skip the AICPU init after cleanup and miss
relatching the globals. Update DeviceRunnerBase::finalize_common() to clear
aicpu_init_launched_ alongside the other teardown state (like binaries_loaded_)
so ensure_aicpu_init_launched() will invoke launch_aicpu_payload again after
reload.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: c205be38-6d08-4883-b531-4d468f4343f7

📥 Commits

Reviewing files that changed from the base of the PR and between 5d4785e and eb45679.

📒 Files selected for processing (24)
  • docs/aicpu-kernel-launch-mechanisms.md
  • docs/callable-identity-registration.md
  • src/a2a3/platform/include/common/kernel_args.h
  • src/a2a3/platform/onboard/aicpu/kernel.cpp
  • src/a2a3/platform/sim/host/device_runner.cpp
  • src/a2a3/platform/sim/host/device_runner.h
  • src/a2a3/runtime/host_build_graph/aicpu/aicpu_executor.cpp
  • src/a2a3/runtime/host_build_graph/runtime/runtime.h
  • src/a2a3/runtime/tensormap_and_ringbuffer/aicpu/aicpu_executor.cpp
  • src/a5/platform/include/common/kernel_args.h
  • src/a5/platform/onboard/aicpu/kernel.cpp
  • src/a5/platform/sim/host/device_runner.cpp
  • src/a5/platform/sim/host/device_runner.h
  • src/a5/runtime/host_build_graph/aicpu/aicpu_executor.cpp
  • src/a5/runtime/host_build_graph/runtime/runtime.h
  • src/a5/runtime/tensormap_and_ringbuffer/aicpu/aicpu_executor.cpp
  • src/common/aicpu_loader/host/load_aicpu_op.cpp
  • src/common/aicpu_loader/host/load_aicpu_op.h
  • src/common/platform/onboard/host/c_api_shared.cpp
  • src/common/platform/onboard/host/device_runner_base.cpp
  • src/common/platform/onboard/host/device_runner_base.h
  • src/common/platform/sim/host/c_api_shared.cpp
  • src/common/platform/sim/host/device_runner_base.cpp
  • src/common/platform/sim/host/device_runner_base.h

Comment thread src/common/platform/onboard/host/device_runner_base.cpp
@ChaoWao
ChaoWao force-pushed the refactor/aicpu-init-register-callable branch 2 times, most recently from 3eba236 to 298d96f Compare June 30, 2026 03:09
Per-device-fixed fields rode on every per-task KernelArgs launch even
though their values never change across runs. Lift them into a new
worker-init-time entry and slim the callable-registration payload.

- Add InitArgs { device_id, log_level, log_info_v } and a new
  simpler_aicpu_init entry, launched once per device from
  ensure_device_initialized(). It latches these into the resident AICPU
  SO globals, so exec / register_callable no longer re-push them. Remove
  the corresponding setters from simpler_aicpu_exec and drop the fields
  from KernelArgs (regs / pmu_reg_addrs / ffts stay per-run; a5 AICore
  still reads regs off the device KernelArgs copy).
- Rename the prewarm path to register_callable end to end
  (simpler_aicpu_prewarm_callable -> simpler_aicpu_register_callable,
  aicpu_prewarm_callable -> aicpu_register_callable, host
  prewarm_callable -> aicpu_register_callable, KernelNames::PrewarmName
  -> RegisterCallableName, add InitName).
- Introduce RegisterCallableArgs carrying only the orch-SO descriptor
  extracted from Runtime (callable id, dev SO addr/size, entry/config
  symbol names) so the register path no longer H2D's a full Runtime.
  Refactor ensure_orch_so_loaded into a core taking those values; the
  run-path Runtime* wrapper and the register entry both delegate to it.
- Generalize the AICPU launch path to void*+size so the three entries
  (exec / init / register_callable) share one mechanism; register all
  three symbols in the inner-SO JSON.
- hbg variants are no-ops (host-side orchestration); add the two missing
  dev_orch_so getters to hbg Runtime so the shared sim path compiles.

Validated: a2a3+a5 build clean; sim register/exec paths pass on both
runtimes; full a2a3 onboard sweep passes (HBG + TMARB).
@ChaoWao
ChaoWao merged commit 6d938bf into hw-native-sys:main Jun 30, 2026
30 of 31 checks passed
@ChaoWao
ChaoWao deleted the refactor/aicpu-init-register-callable branch June 30, 2026 03:44
ChaoWao added a commit that referenced this pull request Jun 30, 2026
…rwarding + KernelArgs cruft (#1207)

The device register-callable entry was a platform-layer forwarding shell
(simpler_aicpu_register_callable -> runtime aicpu_register_callable) that every
runtime had to satisfy by link-time strong symbol, forcing host_build_graph to
carry a no-op it never uses. Move the entry to where the capability lives and
let the runtime advertise it, so the common/platform layers hold no
runtime-specific symbol knowledge.

- The TMARB runtime now exports simpler_aicpu_register_callable(void*) directly
  (was the platform shell forwarding to aicpu_register_callable). The platform
  kernel.cpp forwarding shell and its extern decl are deleted (a2a3 + a5).
- host_build_graph no longer defines the no-op: it simply does not export the
  symbol. Its inner SO links, JSON-registers, and loads without it.
- Each runtime's host part reports the AICPU entry symbols it exports beyond the
  base {exec, init} via a new runtime_extra_aicpu_symbols() — TMARB returns
  register_callable, hbg returns none. The common AICPU loader builds its
  JSON-registration + handle-resolution set from base + runtime-reported extras,
  so it no longer hardcodes any runtime-specific symbol. The sim runners dlsym
  the new exported name (optional; absent on hbg).

KernelArgs cleanup (leftover from the InitArgs split in #1201):
- Remove the dead a2a3 KernelArgs::device_id (orch device id is latched once via
  InitArgs/simpler_aicpu_init; no per-run reader remained).
- Reorder both arches' KernelArgs so all uint64_t precede the uint32_t tail,
  which removes the explicit _pad alignment fillers entirely. runtime_args@0 /
  regs@8 stay offset-locked (static_asserts hold).
- Fix stale comments that still described log config / device id as travelling
  on per-run KernelArgs (platform_regs.h, device_log.{h,cpp}, host_log.{h,cpp},
  device_runner_base.h init_runtime_args_with_metadata).

Validated: a2a3+a5 build clean; TMARB sim register->run passes; a2a3 onboard
passes for both runtimes — hbg loads and runs without exporting
simpler_aicpu_register_callable, TMARB register path intact.
ChaoWao added a commit to ChaoWao/simpler-fork that referenced this pull request Jun 30, 2026
…tail

Make the host/device boundary of the tensormap_and_ringbuffer (trb) Runtime
explicit in the type system instead of resting on a field-ordering
convention, and drop the register-only fields that the RegisterCallableArgs
hand-off (hw-native-sys#1201/hw-native-sys#1203/hw-native-sys#1207) already superseded.

Device-read fields move into a named first member
`DeviceRuntimeLaunchDesc dev` (offset 0); host-only state stays in the tail
and is no longer uploaded. The H2D rtMemcpy and the AICPU cache_invalidate
narrow from sizeof(Runtime) (~34KB) to sizeof(dev).

- runtime.h (a2a3+a5): define DeviceRuntimeLaunchDesc, nest as `dev`, add
  static_asserts (offsetof==0, is_standard_layout_v, is_trivially_copyable_v,
  sizeof%64==0) and inline accessors so the shared platform layer compiles
  against both trb and hbg Runtimes; trb-only device code reads runtime->dev.X
  directly. The struct is alignas(64) so sizeof stays a cache-line multiple and
  cache_invalidate_range(sizeof(dev)) never rounds into a neighbouring line.
- shared/runtime.cpp: ctor + getters/setters forward into dev.*; define
  runtime_device_copy_size() = sizeof(DeviceRuntimeLaunchDesc). hbg defines
  it = sizeof(Runtime) (uploads the whole object). device_runner_helpers.cpp
  uses it for both the alloc and the rtMemcpy length, staying runtime-agnostic.
- Drop the register-only fields (dev_orch_so_addr_/size_,
  device_orch_func_name_/config_name_, register_new_callable_id_) from trb
  Runtime and the parity copies from hbg. The sim register path builds
  RegisterCallableArgs straight from CallableState (mirroring onboard) instead
  of round-tripping through a throwaway Runtime; the dead post-run
  register_new_callable_id() commit gate is removed; set_active_callable_id
  loses its is_new param and stamp_orch_so collapses to setting the cid.
- test_runtime_orch_so.cpp now pins the RegisterCallableArgs POD shape.
- Drop the unused RUNTIME_MAX_ORCH_SO_SIZE macro (no users; dead pre-PR).

Verified: a2a3+a5 sim+onboard builds (trb+hbg); a2a3/a5 sim prepared_callable
+ orch_so_cache; a2a3 onboard prepared_callable (dlopen-count exactly-once) +
orch_so_cache + dummy_task + mixed_example; hbg a2a3 onboard regression.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
ChaoWao added a commit that referenced this pull request Jun 30, 2026
…tail (#1216)

Make the host/device boundary of the tensormap_and_ringbuffer (trb) Runtime
explicit in the type system instead of resting on a field-ordering
convention, and drop the register-only fields that the RegisterCallableArgs
hand-off (#1201/#1203/#1207) already superseded.

Device-read fields move into a named first member
`DeviceRuntimeLaunchDesc dev` (offset 0); host-only state stays in the tail
and is no longer uploaded. The H2D rtMemcpy and the AICPU cache_invalidate
narrow from sizeof(Runtime) (~34KB) to sizeof(dev).

- runtime.h (a2a3+a5): define DeviceRuntimeLaunchDesc, nest as `dev`, add
  static_asserts (offsetof==0, is_standard_layout_v, is_trivially_copyable_v,
  sizeof%64==0) and inline accessors so the shared platform layer compiles
  against both trb and hbg Runtimes; trb-only device code reads runtime->dev.X
  directly. The struct is alignas(64) so sizeof stays a cache-line multiple and
  cache_invalidate_range(sizeof(dev)) never rounds into a neighbouring line.
- shared/runtime.cpp: ctor + getters/setters forward into dev.*; define
  runtime_device_copy_size() = sizeof(DeviceRuntimeLaunchDesc). hbg defines
  it = sizeof(Runtime) (uploads the whole object). device_runner_helpers.cpp
  uses it for both the alloc and the rtMemcpy length, staying runtime-agnostic.
- Drop the register-only fields (dev_orch_so_addr_/size_,
  device_orch_func_name_/config_name_, register_new_callable_id_) from trb
  Runtime and the parity copies from hbg. The sim register path builds
  RegisterCallableArgs straight from CallableState (mirroring onboard) instead
  of round-tripping through a throwaway Runtime; the dead post-run
  register_new_callable_id() commit gate is removed; set_active_callable_id
  loses its is_new param and stamp_orch_so collapses to setting the cid.
- test_runtime_orch_so.cpp now pins the RegisterCallableArgs POD shape.
- Drop the unused RUNTIME_MAX_ORCH_SO_SIZE macro (no users; dead pre-PR).

Verified: a2a3+a5 sim+onboard builds (trb+hbg); a2a3/a5 sim prepared_callable
+ orch_so_cache; a2a3 onboard prepared_callable (dlopen-count exactly-once) +
orch_so_cache + dummy_task + mixed_example; hbg a2a3 onboard regression.
doraemonmj pushed a commit to doraemonmj/simpler_wc that referenced this pull request Jul 1, 2026
hw-native-sys#1201)

Per-device-fixed fields rode on every per-task KernelArgs launch even
though their values never change across runs. Lift them into a new
worker-init-time entry and slim the callable-registration payload.

- Add InitArgs { device_id, log_level, log_info_v } and a new
  simpler_aicpu_init entry, launched once per device from
  ensure_device_initialized(). It latches these into the resident AICPU
  SO globals, so exec / register_callable no longer re-push them. Remove
  the corresponding setters from simpler_aicpu_exec and drop the fields
  from KernelArgs (regs / pmu_reg_addrs / ffts stay per-run; a5 AICore
  still reads regs off the device KernelArgs copy).
- Rename the prewarm path to register_callable end to end
  (simpler_aicpu_prewarm_callable -> simpler_aicpu_register_callable,
  aicpu_prewarm_callable -> aicpu_register_callable, host
  prewarm_callable -> aicpu_register_callable, KernelNames::PrewarmName
  -> RegisterCallableName, add InitName).
- Introduce RegisterCallableArgs carrying only the orch-SO descriptor
  extracted from Runtime (callable id, dev SO addr/size, entry/config
  symbol names) so the register path no longer H2D's a full Runtime.
  Refactor ensure_orch_so_loaded into a core taking those values; the
  run-path Runtime* wrapper and the register entry both delegate to it.
- Generalize the AICPU launch path to void*+size so the three entries
  (exec / init / register_callable) share one mechanism; register all
  three symbols in the inner-SO JSON.
- hbg variants are no-ops (host-side orchestration); add the two missing
  dev_orch_so getters to hbg Runtime so the shared sim path compiles.

Validated: a2a3+a5 build clean; sim register/exec paths pass on both
runtimes; full a2a3 onboard sweep passes (HBG + TMARB).
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