XNNPACK icon indicating copy to clipboard operation
XNNPACK copied to clipboard

Enable AVXVNNI microkernels for mobile platforms

Open soniravi31 opened this issue 10 months ago • 1 comments

AlderLake onwards x86 mobile platform supports avxvnni

soniravi31 avatar Feb 18 '25 08:02 soniravi31

There is another PR that eliminates XNN_PLATFORM_MOBILE, which would also satisfy this Android requirement? https://github.com/google/XNNPACK/pull/8509

This PR would fully enable all x86 microkernels on all devices. If the NDK doesnt support a new ISA, the bazel build has a mechanism to disable by ISA. e.g. --define=xnn_enable_avx512amx=false

For CMake we rely on compiler version, which mostly works. To find compiler versions, I found godbolt is awesome for this, letting you take a code snippet and try gcc, visual c and clang, with different versions, to find which version is required for the compiler flag to be recognized. pytorch cmake has a different approach of compiling a code snippet with the flags needed, and if that doesnt work, the ISA is disabled.

fbarchard avatar May 28 '25 22:05 fbarchard