You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 273ecf9
Browse filesBrowse the repository at this point in the historyBrowse files
[CoreAI] Record ordered I/O names in the delegate manifest (pytorch#23278)
The Core AI runtime binds ExecuTorch inputs and outputs to the .aimodel
function's inputs and outputs by name. This PR makes the exporter name
the delegate boundary explicitly and record those names, in boundary
order, in the delegate manifest, so the runtime never relies on
dictionary iteration order.
* Explicit boundary names (compiler/preprocess.py): preprocess passes
input_0…input_N and output_0…output_M to coreai-torch, one per
ExecuTorch user input and output as reported by _edge_io. State
arguments for delegate-owned mutated buffers aren't boundary I/O, so the
converter keeps its FX placeholder names for them.
* Manifest bindings: source (inline) and AOT (aot_compiled_inline)
manifests now include:
* function: the entrypoint name, "main".
* input_names / output_names: read by the new coreai_io_names
(compiler/io_compat.py) in graph argument and result order. State
arguments, and the results they name, are skipped.
* Name check: assert_io_compatible now also compares those names with
what ExecuTorch expects. That catches I/O that is reordered but has the
same dtype and shape, which the existing dtype and shape checks can't
tell apart.
* Enumerated shapes: names are read before apply_enumerated_shapes runs,
because coreai-core 1.0.0b3's set_static_shape_config replaces main with
per-shape main_<key> clones (which keep the same names).
apply_enumerated_shapes now takes the converter's names as a required
argument, so the shape config matches the renamed inputs.
The backend is under construction, so the manifest format carries no
version or compatibility guarantees.
0 commit comments