Skip to content

Move aliased_io into AliasInfo. #1687

Merged
wujingyue merged 2 commits intomainfrom
wjy/flatten
Jan 27, 2024
Merged

Move aliased_io into AliasInfo. #1687
wujingyue merged 2 commits intomainfrom
wjy/flatten

Conversation

@wujingyue
Copy link
Collaborator

@wujingyue wujingyue commented Jan 27, 2024

This makes getOutputAlias easier to use. This will eventually help #1669 represent outputs that require evaluation but are not an alias. For that, we'll need to

  1. Rename Alias* to Allocation*.
  2. Rename AllocationType::PointerArithmetic to AllocationType::Evaluate.
  3. When a MmaOp segment needs ATen evaluation, set its output allocation to .type=AllocationType::Evaluate,aliased_io=nullptr.

@wujingyue wujingyue marked this pull request as draft January 27, 2024 00:07
@wujingyue wujingyue changed the title WIP Move aliased_io into AliasInfo. Jan 27, 2024
@wujingyue
Copy link
Collaborator Author

!build

@wujingyue wujingyue requested a review from Priya2698 January 27, 2024 00:27
@wujingyue wujingyue marked this pull request as ready for review January 27, 2024 00:27
@Priya2698
Copy link
Collaborator

This makes getOutputAlias easier to use. This will eventually help #1669 represent outputs that require evaluation but are not an alias. For that, we'll need to

  1. Rename Alias* to Allocation*.
  2. Rename AllocationType::PointerArithmetic to AllocationType::Evaluate.
  3. When a MmaOp segment needs ATen evaluation, set its output allocation to .type=AllocationType::Evaluate,aliased_io=nullptr.

Are these changes supposed to be in future PRs?

@wujingyue
Copy link
Collaborator Author

Yes

Copy link
Collaborator

@Priya2698 Priya2698 left a comment

Choose a reason for hiding this comment

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

LGTM.

Base automatically changed from wjy/alias to main January 27, 2024 01:16
@wujingyue
Copy link
Collaborator Author

!build

@wujingyue wujingyue merged commit d8589a4 into main Jan 27, 2024
@wujingyue wujingyue deleted the wjy/flatten branch January 27, 2024 02:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants