mirror of
https://github.com/HChaZZY/Stockfish.git
synced 2025-12-06 10:53:50 +08:00
Update clang-format to v20
closes https://github.com/official-stockfish/Stockfish/pull/6085 No functional change
This commit is contained in:
committed by
Joost VandeVondele
parent
c13c1d2c30
commit
2662d6bf35
@@ -9,7 +9,7 @@ AllowAllParametersOfDeclarationOnNextLine: true
|
||||
AllowShortCaseLabelsOnASingleLine: false
|
||||
AllowShortEnumsOnASingleLine: false
|
||||
AllowShortIfStatementsOnASingleLine: false
|
||||
AlwaysBreakTemplateDeclarations: Yes
|
||||
BreakTemplateDeclarations: Yes
|
||||
BasedOnStyle: WebKit
|
||||
BitFieldColonSpacing: After
|
||||
BinPackParameters: false
|
||||
|
||||
8
.github/workflows/clang-format.yml
vendored
8
.github/workflows/clang-format.yml
vendored
@@ -25,11 +25,11 @@ jobs:
|
||||
ref: ${{ github.event.pull_request.head.sha }}
|
||||
|
||||
- name: Run clang-format style check
|
||||
uses: jidicula/clang-format-action@f62da5e3d3a2d88ff364771d9d938773a618ab5e # @v4.11.0
|
||||
uses: jidicula/clang-format-action@4726374d1aa3c6aecf132e5197e498979588ebc8 # @v4.15.0
|
||||
id: clang-format
|
||||
continue-on-error: true
|
||||
with:
|
||||
clang-format-version: "18"
|
||||
clang-format-version: "20"
|
||||
exclude-regex: "incbin"
|
||||
|
||||
- name: Comment on PR
|
||||
@@ -37,9 +37,9 @@ jobs:
|
||||
uses: thollander/actions-comment-pull-request@fabd468d3a1a0b97feee5f6b9e499eab0dd903f6 # @v2.5.0
|
||||
with:
|
||||
message: |
|
||||
clang-format 18 needs to be run on this PR.
|
||||
clang-format 20 needs to be run on this PR.
|
||||
If you do not have clang-format installed, the maintainer will run it when merging.
|
||||
For the exact version please see https://packages.ubuntu.com/noble/clang-format-18.
|
||||
For the exact version please see https://packages.ubuntu.com/plucky/clang-format-20.
|
||||
|
||||
_(execution **${{ github.run_id }}** / attempt **${{ github.run_attempt }}**)_
|
||||
comment_tag: execution
|
||||
|
||||
@@ -163,8 +163,8 @@ lsx = no
|
||||
lasx = no
|
||||
STRIP = strip
|
||||
|
||||
ifneq ($(shell which clang-format-18 2> /dev/null),)
|
||||
CLANG-FORMAT = clang-format-18
|
||||
ifneq ($(shell which clang-format-20 2> /dev/null),)
|
||||
CLANG-FORMAT = clang-format-20
|
||||
else
|
||||
CLANG-FORMAT = clang-format
|
||||
endif
|
||||
|
||||
@@ -122,8 +122,7 @@ using psqt_vec_t = int32x4_t;
|
||||
#define vec_add_16(a, b) vaddq_s16(a, b)
|
||||
#define vec_sub_16(a, b) vsubq_s16(a, b)
|
||||
#define vec_mulhi_16(a, b) vqdmulhq_s16(a, b)
|
||||
#define vec_zero() \
|
||||
vec_t { 0 }
|
||||
#define vec_zero() vec_t{0}
|
||||
#define vec_set_16(a) vdupq_n_s16(a)
|
||||
#define vec_max_16(a, b) vmaxq_s16(a, b)
|
||||
#define vec_min_16(a, b) vminq_s16(a, b)
|
||||
@@ -133,8 +132,7 @@ using psqt_vec_t = int32x4_t;
|
||||
#define vec_store_psqt(a, b) *(a) = (b)
|
||||
#define vec_add_psqt_32(a, b) vaddq_s32(a, b)
|
||||
#define vec_sub_psqt_32(a, b) vsubq_s32(a, b)
|
||||
#define vec_zero_psqt() \
|
||||
psqt_vec_t { 0 }
|
||||
#define vec_zero_psqt() psqt_vec_t{0}
|
||||
#define NumRegistersSIMD 16
|
||||
#define MaxChunkSize 16
|
||||
|
||||
|
||||
@@ -164,7 +164,7 @@ class ThreadPool {
|
||||
std::vector<std::unique_ptr<Thread>> threads;
|
||||
std::vector<NumaIndex> boundThreadToNumaNode;
|
||||
|
||||
uint64_t accumulate(std::atomic<uint64_t> Search::Worker::*member) const {
|
||||
uint64_t accumulate(std::atomic<uint64_t> Search::Worker::* member) const {
|
||||
|
||||
uint64_t sum = 0;
|
||||
for (auto&& th : threads)
|
||||
|
||||
Reference in New Issue
Block a user