File tree Expand file tree Collapse file tree 2 files changed +17
-4
lines changed Expand file tree Collapse file tree 2 files changed +17
-4
lines changed Original file line number Diff line number Diff line change @@ -365,10 +365,7 @@ buck_targets = [
365
365
" //extension/llm/custom_ops:custom_ops" ,
366
366
]
367
367
filters = [
368
- # Second clause is to pick up fht_neon.c/fht_avx.c from FFHT. TODO:
369
- # remove filters and patch extract_sources.py's Buck query to fetch
370
- # srcs; presumably filters is here to remove .h files.
371
- " (.cpp$)|(fht.*\\ .c$)" ,
368
+ " .cpp$" ,
372
369
]
373
370
excludes = [
374
371
" ^codegen" ,
Original file line number Diff line number Diff line change @@ -45,6 +45,22 @@ list(APPEND custom_ops_libs cpuinfo)
45
45
list (APPEND custom_ops_libs cpublas )
46
46
list (APPEND custom_ops_libs eigen_blas )
47
47
48
+ if (CMAKE_SYSTEM_PROCESSOR MATCHES "^(aarch64|arm64|armv7)$" )
49
+ list (APPEND _custom_ops__srcs
50
+ "extension/llm/custom_ops/spinquant/third-party/FFHT/fht_neon.c"
51
+ )
52
+ elseif (CMAKE_SYSTEM_PROCESSOR STREQUAL "x86_64" )
53
+ list (APPEND _custom_ops__srcs
54
+ "extension/llm/custom_ops/spinquant/third-party/FFHT/fht_avx.c"
55
+ )
56
+ else ()
57
+ message (
58
+ FATAL_ERROR
59
+ "Unsupported CMAKE_SYSTEM_PROCESSOR ${CMAKE_SYSTEM_PROCESSOR} . (If \
60
+ 32-bit x86, try using fht_avx.c and send a PR if it works!)"
61
+ )
62
+ endif ()
63
+
48
64
list (TRANSFORM _custom_ops__srcs PREPEND "${EXECUTORCH_ROOT} /" )
49
65
50
66
if (NOT EXECUTORCH_BUILD_XNNPACK )
You can’t perform that action at this time.
0 commit comments