Skip to content

Commit

Permalink
Disable avxvnni in XNN pack when compiling tflite for Android x86 & x…
Browse files Browse the repository at this point in the history
…86_64 to avoid compilation error.
  • Loading branch information
emgucv committed May 6, 2024
1 parent 2177266 commit d9f6a3e
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions platforms/android/build_tflite_android
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,10 @@ extra_flags=
if [ \( -n "$1" \) ]; then
if [ "$1" = "x86" ]; then
arch="x86"
extra_flags="--define=xnn_enable_avxvnni=false"
elif [ "$1" = "x86_64" ]; then
arch="x86_64"
extra_flags="--define=xnn_enable_avxvnni=false"
elif [ "$1" = "arm" ]; then
arch="armeabi-v7a"
extra_flags="--define=xnn_enable_arm_i8mm=false"
Expand Down Expand Up @@ -37,6 +39,8 @@ bazel --output_user_root=$OUTPUT_USER_ROOT \
#--action_env ANDROID_NDK_HOME=/usr/lib/android-sdk/ndk/25.2.9519653 \
#--action_env ANDROID_BUILD_TOOLS_VERSION=debian \

bazel --version

set +x
#bazel clean
cd ..
Expand Down

0 comments on commit d9f6a3e

Please sign in to comment.