pytorch / pytorch/executorch

Add torchao kernels to xcframework

Open
#10,694 2 comments 1 reaction 1 assignee View on GitHub

@hinriksnaer is already working on this.

Since May 16, 2025.

good first issue module: build/install module: ios module: quantization triaged
Dominant language
Python
Stars
5k
Forks
1.2k
Avg merge
2d 10h
Merged PRs (30d)
581

Description

🚀 The feature, motivation and pitch

We can build low-bit kernels on Macbook (https://github.com/pytorch/executorch/tree/main/examples/models/llama#running-with-low-bit-kernels), but we don't currently build these as part of the main ExecuTorch CMakeLists.txt.

Instead they are built inside the runner code here: https://github.com/pytorch/executorch/blob/main/examples/models/llama/CMakeLists.txt#L118-L137

In this task, we want to add an option to build this kernel library to the ET CMakeLists.txt (https://github.com/pytorch/executorch/blob/main/CMakeLists.txt) guarded under EXECUTORCH_BUILD_KERNELS_TORCHAO, and add them to the xcframeworks (https://github.com/pytorch/executorch/blob/main/scripts/build_apple_frameworks.sh).

This will let us run low-bit kernels on the iOS app.

cc @larryliu0820 @jathu @kimishpatel @jerryzh168 @shoumikhin @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.