pytorch / pytorch/executorch

Is weight sharing in Vulkan backend supported?

Open
#11,780 1 comment 0 reactions 1 assignee View on GitHub

@SS-JIA is already working on this.

Since Jun 18, 2025.

module: vulkan triaged
Dominant language
Python
Stars
5k
Forks
1.2k
Avg merge
2d 10h
Merged PRs (30d)
581

Description

🐛 Describe the bug

In the v0.6.0 release notes, I noticed that for XNNPack the build option ENABLE_XNNPACK_WEIGHTS_CACHE was introduced to enable weight sharing across multiple methods within the same model. However, when following the Vulkan tutorial and documentation, there doesn’t appear to be an equivalent option for weight sharing.

Does the Vulkan backend in v0.6.0 support weight sharing (either through a CMake build flag or a runtime option)?

If not, are there plans to introduce weight sharing or similar weight-caching features in future Vulkan releases?

In the meantime, what optimizations or best practices (e.g., memory layout tweaks, shader tuning) would you recommend to improve Vulkan performance?

Versions

executorch v0.6.0

cc @SS-JIA @manuelcandales @cbilgin

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.