Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion .github/workflows/build-presets.yml
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ jobs:
strategy:
fail-fast: false
matrix:
preset: [windows]
preset: [pybind, windows]
with:
job-name: build
ref: ${{ github.event_name == 'pull_request' && github.event.pull_request.head.sha || github.sha }}
Expand All @@ -122,14 +122,17 @@ jobs:
Set-PSDebug -Trace 1
\$ErrorActionPreference = 'Stop'
\$PSNativeCommandUseErrorActionPreference = \$true

conda create --yes --quiet -n et python=3.12
conda activate et
python install_requirements.py

cmake --preset ${{ matrix.preset }} -T ClangCL
if (\$LASTEXITCODE -ne 0) {
Write-Host "CMake configuration was unsuccessful. Exit code: \$LASTEXITCODE."
exit \$LASTEXITCODE
}

\$numCores = [System.Environment]::GetEnvironmentVariable('NUMBER_OF_PROCESSORS') - 1
cmake --build cmake-out -j \$numCores
if (\$LASTEXITCODE -ne 0) {
Expand Down
8 changes: 8 additions & 0 deletions backends/xnnpack/cmake/Dependencies.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,14 @@ else()
)
endif()

if(WIN32)
# These XNNPACK options don't currently build on Windows.
set_overridable_option(XNNPACK_ENABLE_AVX256SKX OFF)
set_overridable_option(XNNPACK_ENABLE_AVX256VNNI OFF)
set_overridable_option(XNNPACK_ENABLE_AVX256VNNIGFNI OFF)
set_overridable_option(XNNPACK_ENABLE_AVX512BF16 OFF)
endif()

set(XNNPACK_BUILD_ALL_MICROKERNELS
OFF
CACHE BOOL ""
Expand Down
5 changes: 5 additions & 0 deletions extension/data_loader/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,11 @@ if(NOT ET_HAVE_SYS_MMAN_H AND NOT WIN32)
"extension/data_loader/mmap_data_loader.cpp"
)
endif()
if(WIN32)
list(APPEND _extension_data_loader__srcs
"extension/data_loader/mman_windows.cpp"
)
endif()
list(TRANSFORM _extension_data_loader__srcs PREPEND "${EXECUTORCH_ROOT}/")
add_library(extension_data_loader ${_extension_data_loader__srcs})
target_link_libraries(extension_data_loader executorch_core)
Expand Down
3 changes: 2 additions & 1 deletion tools/cmake/preset/pybind.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,13 @@ set_overridable_option(EXECUTORCH_BUILD_EXTENSION_FLAT_TENSOR ON)
set_overridable_option(EXECUTORCH_BUILD_EXTENSION_DATA_LOADER ON)
set_overridable_option(EXECUTORCH_BUILD_KERNELS_OPTIMIZED ON)
set_overridable_option(EXECUTORCH_BUILD_EXTENSION_MODULE ON)
set_overridable_option(EXECUTORCH_BUILD_EXTENSION_TRAINING ON)

if(CMAKE_SYSTEM_NAME STREQUAL "Darwin")
set_overridable_option(EXECUTORCH_BUILD_COREML ON)
set_overridable_option(EXECUTORCH_BUILD_EXTENSION_TRAINING ON)
elseif(CMAKE_SYSTEM_NAME STREQUAL "Linux")
set_overridable_option(EXECUTORCH_BUILD_COREML ON)
set_overridable_option(EXECUTORCH_BUILD_EXTENSION_TRAINING ON)
elseif(CMAKE_SYSTEM_NAME STREQUAL "Windows" OR CMAKE_SYSTEM_NAME STREQUAL
"WIN32"
)
Expand Down
4 changes: 1 addition & 3 deletions tools/cmake/preset/windows.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,4 @@ set_overridable_option(EXECUTORCH_BUILD_EXTENSION_RUNNER_UTIL ON)
set_overridable_option(EXECUTORCH_BUILD_EXTENSION_TENSOR ON)
set_overridable_option(EXECUTORCH_BUILD_KERNELS_OPTIMIZED ON)
set_overridable_option(EXECUTORCH_BUILD_KERNELS_QUANTIZED ON)

# Below options are not yet buildable on Windows, but should be.
# set_overridable_option(EXECUTORCH_BUILD_XNNPACK ON)
set_overridable_option(EXECUTORCH_BUILD_XNNPACK ON)
Loading