@@ -165,14 +165,14 @@ option(EXECUTORCH_BUILD_ARM_BAREMETAL
165
165
166
166
option (EXECUTORCH_BUILD_COREML "Build the Core ML backend" OFF )
167
167
168
- option (EXECUTORCH_BUILD_KERNELS_CUSTOM "Build the custom kernels" OFF )
169
-
170
- option (EXECUTORCH_BUILD_KERNELS_CUSTOM_AOT "Build the custom ops lib for AOT"
168
+ option (EXECUTORCH_BUILD_EXTENSION_DATA_LOADER "Build the Data Loader extension"
171
169
OFF
172
170
)
173
171
174
- option (EXECUTORCH_BUILD_EXTENSION_DATA_LOADER "Build the Data Loader extension"
175
- OFF
172
+ option (EXECUTORCH_BUILD_EXTENSION_LLM "Build the LLM extension" OFF )
173
+
174
+ option (EXECUTORCH_BUILD_EXTENSION_LLM_AOT
175
+ "Build the LLM extension custom ops lib for AOT" OFF
176
176
)
177
177
178
178
option (EXECUTORCH_BUILD_EXTENSION_MODULE "Build the Module extension" OFF )
@@ -229,12 +229,12 @@ cmake_dependent_option(
229
229
"NOT EXECUTORCH_BUILD_ARM_BAREMETAL" OFF
230
230
)
231
231
232
- if (EXECUTORCH_BUILD_KERNELS_CUSTOM_AOT )
232
+ if (EXECUTORCH_BUILD_EXTENSION_LLM_AOT )
233
233
set (EXECUTORCH_BUILD_EXTENSION_TENSOR ON )
234
- set (EXECUTORCH_BUILD_KERNELS_CUSTOM ON )
234
+ set (EXECUTORCH_BUILD_EXTENSION_LLM ON )
235
235
endif ()
236
236
237
- if (EXECUTORCH_BUILD_KERNELS_CUSTOM )
237
+ if (EXECUTORCH_BUILD_EXTENSION_LLM )
238
238
set (EXECUTORCH_BUILD_KERNELS_OPTIMIZED ON )
239
239
endif ()
240
240
@@ -638,6 +638,10 @@ if(EXECUTORCH_BUILD_EXTENSION_DATA_LOADER)
638
638
add_subdirectory (${CMAKE_CURRENT_SOURCE_DIR} /extension/data_loader)
639
639
endif ()
640
640
641
+ if (EXECUTORCH_BUILD_EXTENSION_LLM)
642
+ add_subdirectory (${CMAKE_CURRENT_SOURCE_DIR} /extension/llm/custom_ops)
643
+ endif ()
644
+
641
645
if (EXECUTORCH_BUILD_EXTENSION_MODULE)
642
646
add_subdirectory (${CMAKE_CURRENT_SOURCE_DIR} /extension/module)
643
647
endif ()
@@ -786,11 +790,6 @@ if(EXECUTORCH_BUILD_PYBIND)
786
790
)
787
791
endif ()
788
792
789
- if (EXECUTORCH_BUILD_KERNELS_CUSTOM)
790
- # TODO: move all custom kernels to ${CMAKE_CURRENT_SOURCE_DIR}/kernels/custom
791
- add_subdirectory (${CMAKE_CURRENT_SOURCE_DIR} /extension/llm/custom_ops)
792
- endif ()
793
-
794
793
if (EXECUTORCH_BUILD_KERNELS_QUANTIZED)
795
794
add_subdirectory (${CMAKE_CURRENT_SOURCE_DIR} /kernels/quantized)
796
795
target_link_options_shared_lib(quantized_ops_lib)
0 commit comments