Skip to content

Conversation

@Lunderberg
Copy link
Contributor

As a follow-up to #11269, starting to add similar quality-of-life functionality to other methods in Schedule. They can only be used when it is unambiguous to do so, and translate the string name into the underlying C++ type before calling the FFI.

  • Allow a block to be passed in by a name.
  • Allow a buffer name to be passed to Schedule.reindex, with the same calling convention as Schedule.transform_layout.

This has previously been implemented for `Schedule.transform_layout`
in apache#11296, extending to allow for
block arguments in all `Schedule` methods.

This change was only made for arguments that must be a `BlockRV`.  For
arguments that may be either a `BlockRV` or another
type (e.g. `Schedule.get_child_blocks` accepts either `BlockRV` or
`LoopRV`), this sugar is not implemented, to avoid ambiguity.
Similar to apache#11269, which added this
functionality to `Schedule.transform_layout`.
@Lunderberg Lunderberg requested a review from vinx13 June 8, 2022 14:22
@vinx13 vinx13 merged commit af01281 into apache:main Jun 9, 2022
Kathryn-cat pushed a commit to Kathryn-cat/tvm that referenced this pull request Jun 10, 2022
…pache#11624)

* [Schedule] Allowed string argument as block arg

This has previously been implemented for `Schedule.transform_layout`
in apache#11296, extending to allow for
block arguments in all `Schedule` methods.

This change was only made for arguments that must be a `BlockRV`.  For
arguments that may be either a `BlockRV` or another
type (e.g. `Schedule.get_child_blocks` accepts either `BlockRV` or
`LoopRV`), this sugar is not implemented, to avoid ambiguity.

* [Schedule] Allowed string argument to Schedule.reindex

Similar to apache#11269, which added this
functionality to `Schedule.transform_layout`.

* CI test update
@Lunderberg Lunderberg deleted the stir_named_block_buffer_args branch June 10, 2022 12:33
Lunderberg added a commit to Lunderberg/tvm that referenced this pull request Aug 31, 2022
Previously, the argument needed to be an integer specifying the index
into the read/write regions of a block.  Now, the argument can be a
string specifying the name of the buffer, or the Buffer object itself.
This is a follow-up from apache#11624.
Lunderberg added a commit to Lunderberg/tvm that referenced this pull request Aug 31, 2022
Previously, the argument needed to be an integer specifying the index
into the read/write regions of a block.  Now, the argument can be a
string specifying the name of the buffer, or the Buffer object itself.
This is a follow-up from apache#11624.
Hzfengsy pushed a commit that referenced this pull request Sep 1, 2022
)

Previously, the argument needed to be an integer specifying the index
into the read/write regions of a block.  Now, the argument can be a
string specifying the name of the buffer, or the Buffer object itself.
This is a follow-up from #11624.
xinetzone pushed a commit to daobook/tvm that referenced this pull request Nov 25, 2022
…che#12661)

Previously, the argument needed to be an integer specifying the index
into the read/write regions of a block.  Now, the argument can be a
string specifying the name of the buffer, or the Buffer object itself.
This is a follow-up from apache#11624.
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.

2 participants