forked from official-stockfish/Stockfish
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'Main_SFNNv9.6.3' into 0425_Main_SFNNv9.6.3
- Loading branch information
Showing
21 changed files
with
360 additions
and
56 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,63 @@ | ||
name: SFNNv6_avx2Upload | ||
on: | ||
workflow_dispatch: | ||
jobs: | ||
SFnpsArmWinBuilds: | ||
name: ${{ matrix.config.name }} | ||
runs-on: ${{ matrix.config.os }} | ||
env: | ||
COMPILER: ${{ matrix.config.compiler }} | ||
COMP: ${{ matrix.config.comp }} | ||
strategy: | ||
matrix: | ||
config: | ||
- name: Windows 2022 Mingw-w64 GCC x86_64 | ||
os: windows-2022 | ||
compiler: g++ | ||
comp: mingw | ||
run_win11_build: true | ||
msys_sys: mingw64 | ||
msys_env: x86_64-gcc | ||
shell: msys2 {0} | ||
|
||
defaults: | ||
run: | ||
working-directory: src | ||
shell: ${{ matrix.config.shell }} | ||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
|
||
- name: Setup msys and install required packages | ||
if: runner.os == 'Windows' | ||
uses: msys2/setup-msys2@v2 | ||
with: | ||
msystem: ${{ matrix.config.msys_sys }} | ||
install: mingw-w64-${{ matrix.config.msys_env }} make git | ||
|
||
- name: Download both networks from the fishtest framework | ||
run: | | ||
make net | ||
- name: win11 build | ||
if: ${{ matrix.config.run_win11_build }} | ||
run: | | ||
make clean | ||
make -j3 profile-build ARCH=x86-64-avx2 COMP=$COMP | ||
make strip ARCH=x86-64-avx2 COMP=$COMP | ||
cp stockfish.exe ../SFNNv6_avx2.exe | ||
- uses: xresloader/upload-to-github-Release@v1 | ||
if: ${{ matrix.config.run_win11_build }} | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
with: | ||
overwrite: false | ||
file: "SFNNv6_avx2.exe" | ||
update_latest_release: false | ||
|
||
- uses: actions/upload-artifact@v4 | ||
if: ${{ matrix.config.run_win11_build }} | ||
with: | ||
name: SFNNv6_avx2 | ||
path: SFNNv6_avx2.exe |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,101 @@ | ||
name: SFnpsArmWinBinariesUpload | ||
on: | ||
workflow_dispatch: | ||
jobs: | ||
SFnpsArmTest: | ||
name: ${{ matrix.config.name }} | ||
runs-on: ${{ matrix.config.os }} | ||
env: | ||
COMPILER: ${{ matrix.config.compiler }} | ||
COMP: ${{ matrix.config.comp }} | ||
strategy: | ||
matrix: | ||
config: | ||
- name: Ubuntu 22.04 NDK armv8 | ||
os: ubuntu-22.04 | ||
compiler: aarch64-linux-android21-clang++ | ||
comp: ndk | ||
run_armv8_tests: true | ||
shell: bash {0} | ||
|
||
- name: Windows 2022 Mingw-w64 GCC x86_64 | ||
os: windows-2022 | ||
compiler: g++ | ||
comp: mingw | ||
run_win11_tests: true | ||
msys_sys: mingw64 | ||
msys_env: x86_64-gcc | ||
shell: msys2 {0} | ||
|
||
defaults: | ||
run: | ||
working-directory: src | ||
shell: ${{ matrix.config.shell }} | ||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
|
||
- name: Setup msys and install required packages | ||
if: runner.os == 'Windows' | ||
uses: msys2/setup-msys2@v2 | ||
with: | ||
msystem: ${{ matrix.config.msys_sys }} | ||
install: mingw-w64-${{ matrix.config.msys_env }} make git | ||
|
||
- name: Download the used network from the fishtest framework | ||
run: make net | ||
|
||
- name: Test armv8 build | ||
if: ${{ matrix.config.run_armv8_tests }} | ||
run: | | ||
export PATH=$ANDROID_NDK_HOME:$PATH | ||
export PATH=$ANDROID_NDK_HOME/toolchains/llvm/prebuilt/linux-x86_64/bin:$PATH | ||
cp nn-*.nnue ../jni | ||
cd ../jni | ||
cp Application_v8.mk Application.mk | ||
ndk-build | ||
cd ../libs/arm64-v8a | ||
cp Stockfish ../../SFnps_armv8 | ||
- uses: xresloader/[email protected] | ||
if: ${{ matrix.config.run_armv8_tests }} | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
with: | ||
overwrite: false | ||
file: "SFnps_armv8" | ||
update_latest_release: false | ||
|
||
- uses: actions/upload-artifact@v4 | ||
if: ${{ matrix.config.run_armv8_tests }} | ||
with: | ||
name: SFnps-armv8 | ||
path: SFnps_armv8 | ||
#path: /home/runner/work/StockfishNPS/StockfishNPS/SFnps_armv8 | ||
|
||
- name: win11 build | ||
if: ${{ matrix.config.run_win11_tests }} | ||
run: | | ||
make clean | ||
make -j profile-build ARCH=x86-64-modern COMP=$COMP | ||
make strip ARCH=x86-64-modern COMP=$COMP | ||
cp stockfish.exe ../SFnps_modern.exe | ||
- uses: xresloader/[email protected] | ||
if: ${{ matrix.config.run_win11_tests }} | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
with: | ||
overwrite: false | ||
file: "SFnps_modern.exe" | ||
update_latest_release: false | ||
|
||
- uses: actions/upload-artifact@v4 | ||
if: ${{ matrix.config.run_win11_tests }} | ||
with: | ||
name: SFnps-modern | ||
path: SFnps_modern.exe | ||
#path: D:\a\StockfishNPS\StockfishNPS\SFnps_modern.exe | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
LOCAL_PATH := $(call my-dir) | ||
include $(CLEAR_VARS) | ||
LOCAL_MODULE := Stockfish | ||
LOCAL_C_INCLUDES := | ||
LOCAL_SRC_FILES := $(wildcard ../src/*.cpp ../src/nnue/*.cpp ../src/nnue/features/*.cpp ../src/syzygy/*.cpp) | ||
LOCAL_CFLAGS += -std=c++17 -O3 -flto -fexperimental-new-pass-manager -Wfatal-errors -Wall -Wextra -Wshadow -DNNUE_EMBEDDING_OFF -DUSE_PTHREADS | ||
LOCAL_CPPFLAGS += | ||
LOCAL_CPP_FEATURES := | ||
|
||
ifeq ($(TARGET_ARCH_ABI), arm64-v8a) | ||
LOCAL_CFLAGS += -DIS_64BIT -DUSE_NEON=8 -DUSE_POPCNT | ||
endif | ||
ifeq ($(TARGET_ARCH_ABI), armeabi-v7a) | ||
LOCAL_CFLAGS += -DUSE_NEON=7 -DUSE_POPCNT | ||
endif | ||
|
||
LOCAL_LDFLAGS += | ||
include $(BUILD_EXECUTABLE) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
APP_ABI := armeabi-v7a | ||
APP_PLATFORM := android-19 | ||
APP_STL := c++_static |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
APP_ABI := arm64-v8a | ||
APP_PLATFORM := android-21 | ||
APP_STL := c++_static |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.