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: #9405 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/197/base
ghstack PR head: https://github.com/pytorch/executorch/tree/gh/SS-JIA/197/head
Merge bot PR base: https://github.com/pytorch/executorch/tree/main
Merge bot PR head: https://github.com/pytorch/executorch/tree/gh/SS-JIA/197/orig
@diff-train-skip-merge

…line`

## Context

Fix changes introduced in #8634 (D70021032).

This change decoupled local work group size from additional specialization constants. As part of this change, when creating a `VkComputePipeline` a temporary `SpecVarList` is created to merge the `WorkgroupSize` with additional specialization constants.

However, this can be an issue with some Vulkan drivers because the `SpecVarList` is a temporary, and thus will be destroyed at the end of the function call. The pointer stored in the `VkSpecializationInfo` will be invalidated, leading to undefined behaviour.


This diff fixes this by restoring the behaviour of `ComputePipeline::Descriptor` storing the `specialization_constants` directly.

Also fix the fact that the `VkSpecializationMapEntry` vector was also a temporary when creating a `VkComputePipeline` by storing it in `ComputePipeline`.

Differential Revision: [D71488015](https://our.internmc.facebook.com/intern/diff/D71488015/)

ghstack-source-id: 272783852
Pull Request resolved: #9405
@pytorchbot pytorchbot requested a review from SS-JIA as a code owner March 20, 2025 19:16
Copy link

pytorch-bot bot commented Mar 20, 2025

🔗 Helpful Links

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

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

❌ 1 New Failure, 72 Pending

As of commit 241fe54 with merge base 6daff83 (image):

NEW FAILURE - The following job has failed:

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

@facebook-github-bot facebook-github-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 Mar 20, 2025
Copy link

This PR needs a release notes: label

If your changes are user facing and intended to be a part of release notes, please use a label starting with release notes:.

If not, please add the topic: not user facing label.

To add a label, you can comment to pytorchbot, for example
@pytorchbot label "topic: not user facing"

For more information, see
https://github.com/pytorch/pytorch/wiki/PyTorch-AutoLabel-Bot#why-categorize-for-release-notes-and-how-does-it-work.

@SS-JIA SS-JIA merged commit 2d6d981 into main Mar 20, 2025
74 of 76 checks passed
@SS-JIA SS-JIA deleted the gh/SS-JIA/197/orig branch March 20, 2025 19:19
oscarandersson8218 pushed a commit to oscarandersson8218/executorch that referenced this pull request Mar 21, 2025
…line` (pytorch#9464)

This PR was created by the merge bot to help merge the original PR into
the main branch.
ghstack PR number: pytorch#9405 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/197/base
ghstack PR head:
https://github.com/pytorch/executorch/tree/gh/SS-JIA/197/head
Merge bot PR base: https://github.com/pytorch/executorch/tree/main
Merge bot PR head:
https://github.com/pytorch/executorch/tree/gh/SS-JIA/197/orig
@diff-train-skip-merge

Co-authored-by: Stephen Jia <ssjia@meta.com>
DannyYuyang-quic pushed a commit to CodeLinaro/executorch that referenced this pull request Apr 2, 2025
…line` (pytorch#9464)

This PR was created by the merge bot to help merge the original PR into
the main branch.
ghstack PR number: pytorch#9405 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/197/base
ghstack PR head:
https://github.com/pytorch/executorch/tree/gh/SS-JIA/197/head
Merge bot PR base: https://github.com/pytorch/executorch/tree/main
Merge bot PR head:
https://github.com/pytorch/executorch/tree/gh/SS-JIA/197/orig
@diff-train-skip-merge

Co-authored-by: Stephen Jia <ssjia@meta.com>
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