Skip to content

Add torch::stable::Tensor sizes and strides#165153

Closed
janeyx99 wants to merge 6 commits intogh/janeyx99/316/basefrom
gh/janeyx99/316/head
Closed

Add torch::stable::Tensor sizes and strides#165153
janeyx99 wants to merge 6 commits intogh/janeyx99/316/basefrom
gh/janeyx99/316/head

Conversation

@janeyx99
Copy link
Contributor

@janeyx99 janeyx99 commented Oct 10, 2025

@pytorch-bot
Copy link

pytorch-bot bot commented Oct 10, 2025

🔗 Helpful Links

🧪 See artifacts and rendered test results at hud.pytorch.org/pr/165153

Note: Links to docs will display an error until the docs builds have been completed.

✅ You can merge normally! (1 Unrelated Failure)

As of commit 2840be9 with merge base d7e2d0a (image):

UNSTABLE - The following job is marked as unstable, possibly due to flakiness on trunk:

This comment was automatically generated by Dr. CI and updates every 15 minutes.

janeyx99 added a commit that referenced this pull request Oct 10, 2025
ghstack-source-id: 0020f24
Pull Request resolved: #165153
janeyx99 added a commit that referenced this pull request Oct 14, 2025
ghstack-source-id: aebf927
Pull Request resolved: #165153
@janeyx99 janeyx99 added release notes: cpp release notes category topic: improvements topic category labels Oct 14, 2025
janeyx99 added a commit that referenced this pull request Oct 14, 2025
ghstack-source-id: c934e77
Pull Request resolved: #165153
janeyx99 added a commit that referenced this pull request Oct 16, 2025
ghstack-source-id: e3c4681
Pull Request resolved: #165153
janeyx99 added a commit that referenced this pull request Oct 20, 2025
ghstack-source-id: 617ecb8
Pull Request resolved: #165153
@janeyx99
Copy link
Contributor Author

janeyx99 commented Nov 5, 2025

@pytorchbot merge

@pytorch-bot pytorch-bot bot added the ciflow/trunk Trigger trunk jobs on your pull request label Nov 5, 2025
@pytorchmergebot
Copy link
Collaborator

Merge started

Your change will be merged once all checks pass (ETA 0-4 Hours).

Learn more about merging in the wiki.

Questions? Feedback? Please reach out to the PyTorch DevX Team

Advanced Debugging
Check the merge workflow status
here

pytorchmergebot pushed a commit that referenced this pull request Nov 7, 2025
Some important notes:
a) Just like IValues steal the ownership of ArrayRefs and any std::vectors in order to convert the inner elements into IValues, we do the same thing with StableIValue. This O(N) traverse is ineluctable.
b) As a result, since StableIValues are owning and our contract is that to<T>(StableIValue) transfers ownership, you cannot ever convert from StableIValue to a nonowning HeaderOnlyArrayRef<V>.

We handle memory similar to AtenTensorHandle, but we have a StableListHandle!

Pull Request resolved: #165953
Approved by: https://github.com/malfet
ghstack dependencies: #164991, #165152, #165153
pytorchmergebot pushed a commit that referenced this pull request Nov 7, 2025
Khanaksahu pushed a commit to Khanaksahu/pytorch that referenced this pull request Nov 17, 2025
Silv3S pushed a commit to Silv3S/pytorch that referenced this pull request Nov 18, 2025
Some important notes:
a) Just like IValues steal the ownership of ArrayRefs and any std::vectors in order to convert the inner elements into IValues, we do the same thing with StableIValue. This O(N) traverse is ineluctable.
b) As a result, since StableIValues are owning and our contract is that to<T>(StableIValue) transfers ownership, you cannot ever convert from StableIValue to a nonowning HeaderOnlyArrayRef<V>.

We handle memory similar to AtenTensorHandle, but we have a StableListHandle!

Pull Request resolved: pytorch#165953
Approved by: https://github.com/malfet
ghstack dependencies: pytorch#164991, pytorch#165152, pytorch#165153
Silv3S pushed a commit to Silv3S/pytorch that referenced this pull request Nov 18, 2025
@github-actions github-actions bot deleted the gh/janeyx99/316/head branch December 6, 2025 02:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ciflow/trunk Trigger trunk jobs on your pull request Merged release notes: cpp release notes category topic: improvements topic category

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants