Skip to content

Conversation

@pytorchbot
Copy link
Collaborator

This PR was created by the merge bot to help merge the original PR into the main branch.
ghstack PR number: #15704 by @SS-JIA
^ Please use this as the source of truth for the PR details, comments, and reviews
ghstack PR base: https://github.com/pytorch/executorch/tree/gh/SS-JIA/362/base
ghstack PR head: https://github.com/pytorch/executorch/tree/gh/SS-JIA/362/head
Merge bot PR base: https://github.com/pytorch/executorch/tree/gh/SS-JIA/361/orig
Merge bot PR head: https://github.com/pytorch/executorch/tree/gh/SS-JIA/362/orig
Differential Revision: D86674164
@diff-train-skip-merge

ssjia added 3 commits November 10, 2025 13:32
Pull Request resolved: #15702

Title says it all!

With the way the pass is currently written only the first arg will be inspected for q/dq node replacement. As a consequence, the second arg for i.e. binary ops may not have the quantized op be replaced.
ghstack-source-id: 322214453
@exported-using-ghexport

Differential Revision: [D86674169](https://our.internmc.facebook.com/intern/diff/D86674169/)
Pull Request resolved: #15703

Title says it all!

This diff allows quantize/dequantize ops to consume/produce tensors in the `CONTIGUOUS_BUFFER` layout. This can help reduce the number of memory layout transitions needed to execute a model.
ghstack-source-id: 322214457
@exported-using-ghexport

Differential Revision: [D86674166](https://our.internmc.facebook.com/intern/diff/D86674166/)
Pull Request resolved: #15704

Address the TODO comment in the `tag_memory_meta_pass.py` graph pass.

```
        # TODO(ssjia): For most ops, inputs and outputs must be synchronized, so there
        # is no need to constrain output repsets explicitly. Currently, the exceptions
        # (i.e. choose qparams) already define constrined repsets for the output, so
        # there is again no need to explicitly constrain the outputs. If an operator
        # appears later on that does not sync input and output representations, and
        # defines ambiguous repsets for the output tensor(s), then we will need to add
        # additional logic to this function to constrain the output repsets separately
        # from the input repsets.
```

This condition is now fulfilled with the below diff.
ghstack-source-id: 322214459
@exported-using-ghexport

Differential Revision: [D86674164](https://our.internmc.facebook.com/intern/diff/D86674164/)
@pytorchbot pytorchbot requested a review from SS-JIA as a code owner November 11, 2025 18:28
@pytorch-bot
Copy link

pytorch-bot bot commented Nov 11, 2025

🔗 Helpful Links

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

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

⏳ No Failures, 111 Pending

As of commit 27bed93 with merge base aba44fd (image):
💚 Looks good so far! There are no failures yet. 💚

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

@meta-cla meta-cla bot added the CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. label Nov 11, 2025
Base automatically changed from gh/SS-JIA/361/orig to main November 11, 2025 18:47
@SS-JIA SS-JIA merged commit d300a81 into main Nov 11, 2025
143 of 153 checks passed
@SS-JIA SS-JIA deleted the gh/SS-JIA/362/orig branch November 11, 2025 18:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants