Skip to content

Conversation

@Mousius
Copy link
Member

@Mousius Mousius commented Sep 3, 2021

This change introduces a second memory planning phase in the AOT code
generator once the storage rewrite pass has been completed, fixing
incorrectly sized workspaces for a variety of models.

It comes with accompanying tests so we can safely refactor this later.

Also corrected a typo in the TE compiler regards the memory alignment
argument 😸

Co-authored-by: Manupa Karunaratne [email protected]

@Mousius
Copy link
Member Author

Mousius commented Sep 3, 2021

CC @manupa-arm

@Mousius
Copy link
Member Author

Mousius commented Sep 3, 2021

Also CC @mbs-octoml @electriclilies for reviews 😸

@Mousius Mousius force-pushed the aot-memory-planning branch 3 times, most recently from 4fbb9f5 to cc0c43b Compare September 3, 2021 18:51
Copy link
Contributor

@electriclilies electriclilies left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overall, LGTM! I'd like to see CalculateWorkspaceBytes in a pass in the future instead of being run directly in the exectutor, but this is fine for now

@Mousius Mousius force-pushed the aot-memory-planning branch 3 times, most recently from aea2a68 to 97401c5 Compare September 6, 2021 08:51
This change introduces a second memory planning phase in the AOT code
generator once the storage rewrite pass has been completed, fixing
incorrectly sized workspaces for a variety of models.

It comes with accompanying tests so we can safely refactor this later.

Also corrected a typo in the TE compiler regards the memory alignment
argument 😸

Co-authored-by: Manupa Karunaratne <[email protected]>
@Mousius Mousius force-pushed the aot-memory-planning branch from 97401c5 to fdedfed Compare September 6, 2021 12:30
@jroesch
Copy link
Member

jroesch commented Sep 7, 2021

Overall, LGTM! I'd like to see CalculateWorkspaceBytes in a pass in the future instead of being run directly in the exectutor, but this is fine for now

@Mousius is it possible for you guys to put this as a backlog item? will land this version but in general better to try and split these things into passes so we can make the executor code gens function more uniform instead of each one having different arguments/return values, etc.

@jroesch jroesch merged commit 53a3cba into apache:main Sep 7, 2021
ylc pushed a commit to ylc/tvm that referenced this pull request Sep 29, 2021
This change introduces a second memory planning phase in the AOT code
generator once the storage rewrite pass has been completed, fixing
incorrectly sized workspaces for a variety of models.

It comes with accompanying tests so we can safely refactor this later.

Also corrected a typo in the TE compiler regards the memory alignment
argument 😸

Co-authored-by: Manupa Karunaratne <[email protected]>

Co-authored-by: Manupa Karunaratne <[email protected]>
ylc pushed a commit to ylc/tvm that referenced this pull request Jan 13, 2022
This change introduces a second memory planning phase in the AOT code
generator once the storage rewrite pass has been completed, fixing
incorrectly sized workspaces for a variety of models.

It comes with accompanying tests so we can safely refactor this later.

Also corrected a typo in the TE compiler regards the memory alignment
argument 😸

Co-authored-by: Manupa Karunaratne <[email protected]>

Co-authored-by: Manupa Karunaratne <[email protected]>
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.

5 participants