Skip to content

Commit

Permalink
Merge branch 'master' into hidayat/may16_1
Browse files Browse the repository at this point in the history
  • Loading branch information
mr-c authored Aug 29, 2021
2 parents bb2de39 + 647dc12 commit 62232fb
Show file tree
Hide file tree
Showing 586 changed files with 250,385 additions and 14,562 deletions.
4 changes: 2 additions & 2 deletions .azure-pipelines.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@ jobs:
variables:
CC: clang-10
CXX: clang++-10
# CFLAGS: -Weverything -Werror
# CXXFLAGS: -Weverything -Werror
CFLAGS: -Wextra -Werror
CXXFLAGS: -Wextra -Werror
steps:
- script: uname -a && cat /proc/cpuinfo /proc/meminfo
displayName: System Information
Expand Down
2 changes: 1 addition & 1 deletion .cirrus.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ task:
- apt-get install -y ninja-build ninja-build python3-pip python3-setuptools python3-wheel gcovr clang
- pip3 install meson
configure_script:
- /usr/local/bin/meson setup build -Db_coverage=true -Db_sanitize=address,undefined
- /usr/local/bin/meson setup build -Db_coverage=true -Db_sanitize=address,undefined -Db_lundef=false
build_script:
- ninja -C build -v -j 3
test_script:
Expand Down
3 changes: 2 additions & 1 deletion .drone.star
Original file line number Diff line number Diff line change
Expand Up @@ -63,11 +63,12 @@ def main(ctx):
"environment": environment,
"commands": [
"cat /proc/cpuinfo",
"echo 'APT::Acquire::Retries \"3\";' > /etc/apt/apt.conf.d/80-retries",
"apt-get update -y",
"apt-get install -y " + " ".join(packages),
"pip3 install meson",
"meson build -Db_coverage=true || (cat build/meson-logs/meson-log.txt; false)",
"ninja -C build -v test",
"ninja -C build -v test || (cat build/meson-logs/testlog.txt; false)",
],
}
],
Expand Down
250 changes: 120 additions & 130 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@ on:
- 'master'
- 'ci/**'
- '!ci/gha**'
pull_request:
branches:
- 'master'

jobs:
formatting:
Expand Down Expand Up @@ -35,6 +38,12 @@ jobs:
# Make sure neon.h includes all the NEON headers.
- name: Missing NEON includes
run: for f in simde/arm/neon/*.h; do grep -q "include \"neon/$(basename "$f")\"" simde/arm/neon.h || (echo "Missing $f" && exit 1); done
# Make sure sve.h includes all the SVE headers.
- name: Missing SVE includes
run: for f in simde/arm/sve/*.h; do grep -q "include \"sve/$(basename "$f")\"" simde/arm/sve.h || (echo "Missing $f" && exit 1); done
# Make sure msa.h includes all the MSA headers.
- name: Missing MSA includes
run: for f in simde/mips/msa/*.h; do grep -q "include \"msa/$(basename "$f")\"" simde/mips/msa.h || (echo "Missing $f" && exit 1); done
# Make sure we can find the expected header guards. It's easy to miss this when doing C&P
- name: Header guards
run: for file in $(find simde/*/ -name '*.h'); do grep -q "$(echo "$file" | tr '[:lower:]' '[:upper:]' | tr '[:punct:]' '_')" "$file" || (echo "Missing or incorrect header guard in $file" && exit 1); done
Expand All @@ -53,87 +62,30 @@ jobs:
# Check indentation of preprocessor directives.
- name: Preprocessor directive indentation
run: find simde/*/ -name 'avx*.h' -exec pcre2grep -M '{\n#' {} + && exit 1 || exit 0

# Running the tests in SDE is pretty slow, so we put these early
# in the file so hopefully they start sooner.

SDE:
runs-on: ubuntu-latest
strategy:
matrix:
arch: ["icelake-server"]
env:
CC: clang
CXX: clang++
CFLAGS: -march=icelake-server -Wall -Wextra -Werror
CXXFLAGS: -march=icelake-server -Wall -Wextra -Werror
steps:
- uses: actions/checkout@v2
with:
submodules: recursive
- name: CPU Information
run: cat /proc/cpuinfo
- name: Install APT Dependencies
run: sudo add-apt-repository 'ppa:ubuntu-toolchain-r/test' && sudo apt-get update && sudo apt-get install -y ninja-build ninja-build python3-pip python3-setuptools python3-wheel parallel gcovr
- name: Install pip Dependencies
run: pip3 install meson
- name: Download SDE
run: ./test/download-sde.sh ~/sde
- name: Configure
run: ~/.local/bin/meson setup build -Db_coverage=true
- name: Build
run: ninja -C build -v
- name: Test
run: |
find build/test/ -type f -executable -exec parallel ~/sde/sde64 -- ::: {} \;
- name: Coverage Report
run: ninja -C build -v coverage-xml
- name: CodeCov.io
uses: codecov/codecov-action@v1
with:
file: ./build/meson-logs/coverage.xml

sleef-SDE:
runs-on: ubuntu-20.04
strategy:
matrix:
arch: ["icelake-server"]
env:
CC: clang
CXX: clang++
CFLAGS: -march=icelake-server -Wall -Wextra -Werror
CXXFLAGS: -march=icelake-server -Wall -Wextra -Werror
steps:
- uses: actions/checkout@v2
with:
submodules: recursive
- name: CPU Information
run: cat /proc/cpuinfo
- name: Install APT Dependencies
run: sudo add-apt-repository 'ppa:ubuntu-toolchain-r/test' && sudo apt-get update && sudo apt-get install -y ninja-build ninja-build python3-pip python3-setuptools python3-wheel parallel gcovr libsleef-dev
- name: Install pip Dependencies
run: pip3 install meson
- name: Download SDE
run: ./test/download-sde.sh ~/sde
- name: Configure
run: ~/.local/bin/meson setup build -Dsleef=enabled -Db_coverage=true
- name: Build
run: ninja -C build -v
- name: Test
run: |
find build/test/ -type f -executable -exec parallel ~/sde/sde64 -- ::: {} \;
- name: Coverage Report
run: ninja -C build -v coverage-xml
- name: CodeCov.io
uses: codecov/codecov-action@v1
with:
file: ./build/meson-logs/coverage.xml
- name: Stray `&& 0`
run: git grep ' && 0' simde/ test/ && exit 1 || exit 0

x86:
runs-on: ubuntu-latest
strategy:
matrix:
isax: ["", "-msse3", "-mssse3", "-msse4.1", "-msse4.2", "-mavx", "-mfma", "-mavx2", "-march=native"]
isax:
- -mavx512bw -mavx512vl -mavx512cd -mavx512dq -mavx512vbmi -mavx512ifma -mavx512vpopcntdq -mavx512bitalg -mavx512vnni -mvpclmulqdq
- -mavx512bw -mavx512vl -DSIMDE_NATURAL_VECTOR_SIZE=256
- -mavx512f
- -mavx512bw
- -mavx512vl
- -mavx512vl -mavx512dq
- -mavx512cd
- -mavx512dq
- -msse2
- -msse3
- -mssse3
- -msse4.1
- -msse4.2
- -mavx
- -mfma
- -mavx2
env:
CFLAGS: -Wall -Wextra -Werror ${{ matrix.isax }}
CXXFLAGS: -Wall -Wextra -Werror ${{ matrix.isax }}
Expand All @@ -152,76 +104,52 @@ jobs:
- name: Build
run: ninja -C build -v
- name: Test
run: ninja -C build -v test
run: meson test -C build --print-errorlogs --wrapper "${GITHUB_WORKSPACE}/test/check-flags.sh sde"
- name: Coverage Report
run: ninja -C build -v coverage-xml
- name: CodeCov.io
uses: codecov/codecov-action@v1
with:
file: ./build/meson-logs/coverage.xml

avx512:
emscripten:
runs-on: ubuntu-latest
strategy:
matrix:
isax: ["-mavx512f", "-mavx512bw", "-mavx512cd", "-mavx512dq", "-mavx512vl", "-mavx512bw -mavx512vl", "-mavx512vl -mavx512dq"]
env:
CFLAGS: -Wall -Wextra -Werror ${{ matrix.isax }}
CXXFLAGS: -Wall -Wextra -Werror ${{ matrix.isax }}
CFLAGS: -Weverything -Werror -O2 -msimd128
CXXFLAGS: -Weverything -Werror -O2 -msimd128
LDFLAGS: -s ENVIRONMENT=shell -s ASSERTIONS=1
steps:
- uses: actions/checkout@v2
with:
submodules: recursive
- name: CPU Information
run: cat /proc/cpuinfo
- name: Install APT Dependencies
run: sudo add-apt-repository 'ppa:ubuntu-toolchain-r/test' && sudo apt-get update && sudo apt-get install -y ninja-build ninja-build python3-pip python3-setuptools python3-wheel parallel gcovr
run: sudo add-apt-repository ppa:ubuntu-toolchain-r/test && sudo apt-get update && sudo apt-get -yq install ninja-build ninja-build python3-pip python3-setuptools python3-wheel gcovr
- name: Install pip Dependencies
run: pip3 install meson
- name: Configure
run: ~/.local/bin/meson setup build -Db_coverage=true
- name: Build
run: ninja -C build -v
# We can't actually run the tests without AVX-512. GitHub Actions doesn't
# currently support it, and SDE is too slow.
# - name: Test
# run: ninja -C build -v test
# - name: Coverage Report
# run: ninja -C build -v coverage-xml
# - name: CodeCov.io
# uses: codecov/codecov-action@v1
# with:
# file: ./build/meson-logs/coverage.xml

emscripten:
runs-on: ubuntu-latest
env:
CFLAGS: -Weverything -Werror -O3 -msimd128
CXXFLAGS: -Weverything -Werror -O3 -msimd128
steps:
- uses: actions/checkout@v2
with:
submodules: recursive
- name: CPU Information
run: cat /proc/cpuinfo
- name: Install APT Dependencies
run: sudo add-apt-repository ppa:ubuntu-toolchain-r/test && sudo apt-get update && sudo apt-get -yq install ninja-build
- name: Install emscripten
run: |
git clone https://github.com/emscripten-core/emsdk.git
cd emsdk
git clone https://github.com/emscripten-core/emsdk.git /opt/emsdk
cd /opt/emsdk
./emsdk update-tags
./emsdk install tot
./emsdk activate tot
source emsdk_env.sh
- name: Install v8
run: sudo npm install jsvu -g && jsvu --os=linux64 --engines=v8
run: |
sudo npm install jsvu -g
jsvu --os=linux64 --engines=v8
sudo ln -s $HOME/.jsvu/v8 /usr/bin/v8
ls -l /usr/bin/v8
ls -l ~/.jsvu || true
/usr/bin/v8 --help
- name: Configure
run: mkdir test/build && cd test/build && ../../emsdk/upstream/emscripten/emcmake cmake -G Ninja ..
run: ~/.local/bin/meson setup build --optimization 2 --cross-file docker/cross-files/emscripten.cross
- name: Build
run: ninja -C test/build -v
run: ninja -C build -v
- name: Test
run: cd test/build && ~/.jsvu/v8 --experimental-wasm-simd run-tests.js
run: ninja -C build -v test

native-aliases:
runs-on: ubuntu-latest
Expand Down Expand Up @@ -283,16 +211,43 @@ jobs:
with:
file: ./build/meson-logs/coverage.xml

xenial-gcc:
runs-on: ubuntu-16.04
gcc:
strategy:
matrix:
version: ["4.7", "4.8", "4.9", "5"]
include:
# - version: 4.7
# distro: ubuntu-16.04
# arch_flags: -mavx2
# - version: 4.8
# distro: ubuntu-16.04
# arch_flags: -mavx2
# - version: 4.9
# distro: ubuntu-16.04
# arch_flags: -mavx2
- version: 5
distro: ubuntu-16.04
arch_flags: -mavx2
# - version: 6
# distro: ubuntu-18.04
# arch_flags: -march=native
# - version: 7
# distro: ubuntu-18.04
# arch_flags: -march=native
- version: 8
distro: ubuntu-18.04
arch_flags: -march=native
# - version: 9
# distro: ubuntu-20.04
# arch_flags: -march=native
- version: 10
distro: ubuntu-20.04
arch_flags: -march=native
runs-on: ${{ matrix.distro }}
env:
CC: gcc-${{ matrix.version }}
CXX: g++-${{ matrix.version }}
CFLAGS: -mavx2 -Wall -Wextra -Werror
CXXFLAGS: -mavx2 -Wall -Wextra -Werror
CFLAGS: ${{ matrix.arch_flags }} -Wall -Wextra -Werror
CXXFLAGS: ${{ matrix.arch_flags }} -Wall -Wextra -Werror
steps:
- uses: actions/checkout@v2
with:
Expand All @@ -306,18 +261,51 @@ jobs:
- name: Build
run: ninja -C test/build -v
- name: Test
run: ninja -C test/build -v test
run: ctest -C test/build ---output-on-failure

xenial-clang:
runs-on: ubuntu-16.04
clang:
strategy:
matrix:
version: ["3.5", "3.9", "6.0"]
include:
- version: "3.5"
distro: ubuntu-16.04
arch_flags: -mavx2
# - version: "3.6"
# distro: ubuntu-16.04
# arch_flags: -mavx2
# - version: "3.7"
# distro: ubuntu-16.04
# arch_flags: -mavx2
# - version: "3.8"
# distro: ubuntu-16.04
# arch_flags: -mavx2
# - version: "3.9"
# distro: ubuntu-18.04
# arch_flags: -mavx2
# - version: "4.0"
# distro: ubuntu-18.04
# arch_flags: -mavx2
- version: "5.0"
distro: ubuntu-18.04
arch_flags: -mavx2
# - version: "6.0"
# distro: ubuntu-20.04
# arch_flags: -march=native
- version: "7"
distro: ubuntu-20.04
arch_flags: -march=native
# - version: "8"
# distro: ubuntu-20.04
# arch_flags: -march=native
- version: "10"
distro: ubuntu-20.04
arch_flags: -march=native
runs-on: ${{ matrix.distro }}
env:
CC: clang-${{ matrix.version }}
CXX: clang++-${{ matrix.version }}
CFLAGS: -mavx2 -Wall -Wextra -Werror
CXXFLAGS: -mavx2 -Wall -Wextra -Werror
CFLAGS: ${{ matrix.arch_flags }} -Wall -Weverything -Werror -fno-lax-vector-conversions
CXXFLAGS: ${{ matrix.arch_flags }} -Wall -Weverything -Werror -fno-lax-vector-conversions
steps:
- uses: actions/checkout@v2
with:
Expand All @@ -331,7 +319,7 @@ jobs:
- name: Build
run: ninja -C test/build -v
- name: Test
run: ninja -C test/build -v test
run: ctest -C test/build ---output-on-failure

macos:
runs-on: macos-latest
Expand All @@ -356,6 +344,8 @@ jobs:
run: meson setup build -Db_coverage=true
- name: Build
run: ninja -C build -v
- name: Test
run: ninja -C build -v test
- name: Coverage Report
run: ninja -C build -v coverage-xml
- name: CodeCov.io
Expand Down
9 changes: 0 additions & 9 deletions .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,15 +26,6 @@ jobs:
steps:
- name: Checkout repository
uses: actions/checkout@v2
with:
# We must fetch at least the immediate parents so that if this is
# a pull request then we can checkout the head.
fetch-depth: 2

# If this run was triggered by a pull request event, then checkout
# the head of the pull request instead of the merge commit.
- run: git checkout HEAD^2
if: ${{ github.event_name == 'pull_request' }}

# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
Expand Down
Loading

0 comments on commit 62232fb

Please sign in to comment.