[Ethos-U] Replace ethos-u.constants with AllocateConst#15300
[Ethos-U] Replace ethos-u.constants with AllocateConst#15300Lunderberg wants to merge 6 commits intoapache:mainfrom
Conversation
|
Thanks for contributing to TVM! Please refer to the contributing guidelines https://tvm.apache.org/docs/contribute/ for useful information and tips. Please request code reviews from Reviewers by @-ing them in a comment.
Generated by tvm-bot |
|
This change originated while debugging #14985, but ended up being unnecessary for it, and is therefore kept as a separate PR. |
3af8087 to
35ddc1a
Compare
ekalda
left a comment
There was a problem hiding this comment.
Thanks for these improvements @Lunderberg! Looks like it needs a rebase and I'm not sure the changes to codegen_c_host.cc and split_host_device.cc were intentional for this this patch, but otherwise looks all good to me!
|
Thank you for catching the extra changes in this PR. The |
5133f46 to
77a50e9
Compare
Previously, constants for ethos-u were tracked using a function attribute `"ethos-u.constants"`. This predates the introduction of `AllocateConst`, and had comments indicating that it should be replaced with `AllocateConst` when possible. To minimize impact to existing passes, this commit preserves the `"ethos-u.constants"` attribute during ethosu-specific lowering passes. The attribute is converted to `AllocateConst` at the end of the `lower_ethosu` pass, just prior to lowering with the usual TIR passes.
2c8b757 to
f1a16c8
Compare
Previously, constants for ethos-u were tracked using a function attribute
"ethos-u.constants". This predates the introduction ofAllocateConst, and had comments indicating that it should be replaced withAllocateConstwhen possible.To minimize impact to existing passes, this commit preserves the
"ethos-u.constants"attribute during ethosu-specific lowering passes. The attribute is converted toAllocateConstat the end of thelower_ethosupass, just prior to lowering with the usual TIR passes.