Skip to content

functionalization: remove some unnecessary view_copies in inplace views#77713

Closed
bdhirsh wants to merge 17 commits intogh/bdhirsh/235/basefrom
gh/bdhirsh/235/head
Closed

functionalization: remove some unnecessary view_copies in inplace views#77713
bdhirsh wants to merge 17 commits intogh/bdhirsh/235/basefrom
gh/bdhirsh/235/head

Conversation

@bdhirsh
Copy link
Collaborator

@bdhirsh bdhirsh commented May 18, 2022

The original implementation of inplace_view ops was a bit inefficient, because we would re-play the entire stack of views off of the base. We only actually have to run the newly added view meta.

I mostly noticed this because resize_() can act as an inplace_view op, which I handle in the next PR.

Stack from ghstack:

@facebook-github-bot
Copy link
Contributor

facebook-github-bot commented May 18, 2022

🔗 Helpful links

✅ No Failures (0 Pending)

As of commit fe9268e (more details on the Dr. CI page):

Expand to see more

💚 💚 Looks good so far! There are no failures yet. 💚 💚


This comment was automatically generated by Dr. CI (expand for details).

Please report bugs/suggestions to the (internal) Dr. CI Users group.

Click here to manually regenerate this comment.

@bdhirsh bdhirsh requested a review from ezyang May 18, 2022 15:26
…inplace views"

The original implementation of inplace_view ops was a bit inefficient, because we would re-play the **entire** stack of views off of the base. We only actually have to run the newly added view meta.

I mostly noticed this because `resize_()` can act as an inplace_view op, which I handle in the next PR.




[ghstack-poisoned]
bdhirsh added 8 commits May 19, 2022 06:34
…inplace views"

The original implementation of inplace_view ops was a bit inefficient, because we would re-play the **entire** stack of views off of the base. We only actually have to run the newly added view meta.

I mostly noticed this because `resize_()` can act as an inplace_view op, which I handle in the next PR.




[ghstack-poisoned]
…inplace views"

The original implementation of inplace_view ops was a bit inefficient, because we would re-play the **entire** stack of views off of the base. We only actually have to run the newly added view meta.

I mostly noticed this because `resize_()` can act as an inplace_view op, which I handle in the next PR.




[ghstack-poisoned]
…inplace views"

The original implementation of inplace_view ops was a bit inefficient, because we would re-play the **entire** stack of views off of the base. We only actually have to run the newly added view meta.

I mostly noticed this because `resize_()` can act as an inplace_view op, which I handle in the next PR.




[ghstack-poisoned]
…inplace views"

The original implementation of inplace_view ops was a bit inefficient, because we would re-play the **entire** stack of views off of the base. We only actually have to run the newly added view meta.

I mostly noticed this because `resize_()` can act as an inplace_view op, which I handle in the next PR.




[ghstack-poisoned]
…inplace views"

The original implementation of inplace_view ops was a bit inefficient, because we would re-play the **entire** stack of views off of the base. We only actually have to run the newly added view meta.

I mostly noticed this because `resize_()` can act as an inplace_view op, which I handle in the next PR.




[ghstack-poisoned]
…inplace views"

The original implementation of inplace_view ops was a bit inefficient, because we would re-play the **entire** stack of views off of the base. We only actually have to run the newly added view meta.

I mostly noticed this because `resize_()` can act as an inplace_view op, which I handle in the next PR.




[ghstack-poisoned]
…inplace views"

The original implementation of inplace_view ops was a bit inefficient, because we would re-play the **entire** stack of views off of the base. We only actually have to run the newly added view meta.

I mostly noticed this because `resize_()` can act as an inplace_view op, which I handle in the next PR.




[ghstack-poisoned]
…inplace views"

The original implementation of inplace_view ops was a bit inefficient, because we would re-play the **entire** stack of views off of the base. We only actually have to run the newly added view meta.

I mostly noticed this because `resize_()` can act as an inplace_view op, which I handle in the next PR.




[ghstack-poisoned]
bdhirsh added 2 commits May 25, 2022 07:13
…inplace views"

The original implementation of inplace_view ops was a bit inefficient, because we would re-play the **entire** stack of views off of the base. We only actually have to run the newly added view meta.

I mostly noticed this because `resize_()` can act as an inplace_view op, which I handle in the next PR.




[ghstack-poisoned]
…inplace views"

The original implementation of inplace_view ops was a bit inefficient, because we would re-play the **entire** stack of views off of the base. We only actually have to run the newly added view meta.

I mostly noticed this because `resize_()` can act as an inplace_view op, which I handle in the next PR.




[ghstack-poisoned]
@bdhirsh
Copy link
Collaborator Author

bdhirsh commented May 25, 2022

@pytorchbot merge

…inplace views"

The original implementation of inplace_view ops was a bit inefficient, because we would re-play the **entire** stack of views off of the base. We only actually have to run the newly added view meta.

I mostly noticed this because `resize_()` can act as an inplace_view op, which I handle in the next PR.




[ghstack-poisoned]
@pytorchmergebot
Copy link
Collaborator

Merge failed due to Matched rule superuser, but PR #77132 has not been reviewed yet
Raised by https://github.com/pytorch/pytorch/actions/runs/2386272599

…inplace views"

The original implementation of inplace_view ops was a bit inefficient, because we would re-play the **entire** stack of views off of the base. We only actually have to run the newly added view meta.

I mostly noticed this because `resize_()` can act as an inplace_view op, which I handle in the next PR.




[ghstack-poisoned]
@facebook-github-bot facebook-github-bot deleted the gh/bdhirsh/235/head branch May 30, 2022 14:17
facebook-github-bot pushed a commit that referenced this pull request May 31, 2022
…ws (#77713)

Summary:
Pull Request resolved: #77713

Approved by: https://github.com/ezyang

Test Plan: contbuild & OSS CI, see https://hud.pytorch.org/commit/pytorch/pytorch/e9c54ae1c2357651b3377f0cbbdf6d1ac649f6d1

Reviewed By: seemethere

Differential Revision: D36783117

Pulled By: bdhirsh

fbshipit-source-id: 138b2fe0475e9d0046afb9e85624208570bf9dd8
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants