Skip to content

Commit 095e826

Browse files
GregoryComerfacebook-github-bot
authored andcommitted
Add method variants in dynamic shim to use core tensor/evalue/result types (#7834)
Summary: This change adds forward and execute methods to the dynamic shim interface that make use of the core executorch tensor, evalue, and result types. The intent is to allow users to use the "real" ET types, rather than TensorWrapper/EValueWrapper. There are several reasons to do this: 1) Wrapper types are limited in functionality compared to the core types. 2) We need to add more functionality to the wrappers as we support more models, leading to duplicated effort. 3) API surface is inconsistent with ET documentation, which uses the core types. This change should not introduce significant binary size changes, as these new methods are not currently used and are thus optimized out in release builds. When updating call sites to use the new methods and core ET types, impact is <= 5kB (see diffs in this stack). The ET core runtime is designed to be small, so directly including these types should not carry significant size overhead. Reviewed By: metascroy Differential Revision: D67650320 Pulled By: GregoryComer
1 parent 6332238 commit 095e826

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

runtime/core/portable_type/targets.bzl

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ def define_common_targets():
2525
# mean I cant just expose visibility to a single rule.
2626
visibility = [
2727
"//executorch/backends/...",
28+
"//executorch/extension/fb/dynamic_shim/...",
2829
"//executorch/runtime/core/exec_aten/...",
2930
"//executorch/runtime/core/portable_type/test/...",
3031
],

0 commit comments

Comments
 (0)