pytorch / pytorch/executorch

XNNPACK Buck build appears not to enable KleidiAI/SME2 while CMake enables KleidiAI by default

Open
#20,378 3 comments 0 reactions 1 assignee View on GitHub

@digantdesai is already working on this.

Since Jun 18, 2026.

help wanted module: xnnpack partner: arm
Dominant language
Python
Stars
5k
Forks
1.2k
Avg merge
2d 10h
Merged PRs (30d)
581

Description

The CMake path explicitly enables KleidiAI for XNNPACK by default, but I do not see
equivalent enablement in the OSS Buck/Buck2 XNNPACK targets. In particular, in
backends/xnnpack/targets.bzl, the xnnpack_backend target has the
Kleidi flag commented out:

# Uncomment to enable using KleidiAI Kernels
# "-DENABLE_XNNPACK_KLEIDI"

https://github.com/pytorch/executorch/blob/3707efa9f5f4c25a0bafecf7033e286f1faef96f/backends/xnnpack/targets.bzl#L49

Is this intentional?

If CMake defaults KleidiAI to on, is there a reason Buck/Buck2 should not also
default-enable KleidiAI when the target/toolchain supports it?

cc @GregoryComer @digantdesai @cbilgin @JakeStevens @freddan80 @per @zingo @oscarandersson8218 @Sebastian-Larsson @robell @rascani

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.