Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[cache] Pipeline cache to avoid writeable arguments #5

Closed
wants to merge 1 commit into from

Conversation

rsuderman
Copy link
Contributor

Writing to an arg value results in a !torch.tensor argument type which violates write semantics. As scatters are inherently mutative operations on the destination buffer we can internally create a copy then scatter to this copy. This should result in an in-place mutative operation as the dispatch takes ownership of the passed buffer.

Writing to an `arg` value results in a `!torch.tensor` argument type
which violates write semantics. As scatters  are inherently mutative
operations on the destination buffer we can internally create a copy
then scatter to this copy. This should result in an in-place mutative
operation as the dispatch takes ownership of the passed buffer.
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.

1 participant