Skip to content

Commit f6f3322

Browse files
authored
Add ukernel selection logic + clean up KleidiAI integration (#1652)
* UKernel Selection, up, up, up, up * up
1 parent 4780e10 commit f6f3322

20 files changed

+982
-1085
lines changed

.github/workflows/torchao_experimental_test.yml

+16-1
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,22 @@ jobs:
3737
pip install numpy
3838
pip install pytest
3939
USE_CPP=1 pip install .
40-
- name: Run tests
40+
- name: Run python tests
4141
run: |
4242
conda activate venv
4343
pytest torchao/experimental/tests/test_int8_dynamic_activation_intx_weight.py
44+
python torchao/experimental/tests/test_embedding_xbit_quantizer.py
45+
- name: Run kernels/cpu/aarch64/tests
46+
run: |
47+
conda activate venv
48+
pushd torchao/experimental/kernels/cpu/aarch64/tests
49+
sh build_and_run_tests.sh
50+
rm -rf /tmp/cmake-out
51+
popd
52+
- name: Run torchao/experimental/ops/tests
53+
run: |
54+
conda activate venv
55+
pushd torchao/experimental/ops/tests
56+
sh build_and_run_tests.sh
57+
rm -rf /tmp/cmake-out
58+
popd

setup.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -179,7 +179,8 @@ def build_cmake(self, ext):
179179
"cmake",
180180
ext.sourcedir,
181181
"-DCMAKE_BUILD_TYPE=" + build_type,
182-
"-DTORCHAO_BUILD_EXECUTORCH_OPS=OFF",
182+
# Disable now because 1) KleidiAI increases build time, and 2) KleidiAI has accuracy issues due to BF16
183+
"-DTORCHAO_BUILD_KLEIDIAI=OFF",
183184
"-DTorch_DIR=" + torch_dir,
184185
"-DCMAKE_LIBRARY_OUTPUT_DIRECTORY=" + extdir,
185186
],

torchao/experimental/kernels/cpu/aarch64/kleidi/kai_matmul_clamp_f32_qai8dxp1x8_qsi4c32p4x8_1x4x32_neon_dotprod.h

-122
This file was deleted.

torchao/experimental/kernels/cpu/aarch64/kleidi/kai_matmul_clamp_f32_qai8dxp1x8_qsi4c32p8x8_1x8x32_neon_dotprod.h

-123
This file was deleted.

0 commit comments

Comments
 (0)