Skip to content

Commit 5a042ab

Browse files
committed
add more tests
1 parent c3015c8 commit 5a042ab

File tree

2 files changed

+60
-40
lines changed

2 files changed

+60
-40
lines changed

.github/workflows/linux-simple.yml

Lines changed: 59 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -4,35 +4,66 @@ on: [push, pull_request]
44

55
jobs:
66
build:
7-
name: ${{matrix.compiler.cxx}}, C++${{matrix.std}}, ${{matrix.build_type}}
7+
name: ${{matrix.cxx}}, C++${{matrix.std}}, ${{matrix.build_type}}
88
runs-on: ubuntu-20.04
99
strategy:
1010
fail-fast: false
1111
matrix:
1212
compiler:
13-
- {cxx: g++-5, other_pkgs: g++-5}
14-
- {cxx: g++-6, other_pkgs: g++-6}
15-
- {cxx: g++-7, other_pkgs: g++-7}
16-
- {cxx: g++-8, other_pkgs: g++-8}
17-
- {cxx: g++-9, other_pkgs: g++-9}
18-
- {cxx: g++-10, other_pkgs: g++-10}
19-
- {cxx: clang++-6.0, other_pkgs: clang-6.0}
20-
- {cxx: clang++-7, other_pkgs: clang-7}
21-
- {cxx: clang++-8, other_pkgs: clang-8}
22-
- {cxx: clang++-9, other_pkgs: clang-9}
23-
- {cxx: clang++-10, other_pkgs: clang-10}
13+
- g++-5
14+
- g++-6
15+
- g++-7
16+
- g++-8
17+
- g++-9
18+
- g++-10
19+
- clang++-6.0
20+
- clang++-7
21+
- clang++-8
22+
- clang++-9
23+
- clang++-10
2424
build_type: [Debug, Release]
25-
std: [11, 14]
26-
#std: [11, 14, 17, 20]
27-
#exclude:
28-
# - compiler.cxx: "g++-{5,6,7,8,9,10}"
29-
# std: 17
30-
# - compiler.cxx: "g++-{5,6,7,8,9,10}"
31-
# std: 20
32-
# - compiler.cxx: "clang++-{6.0,7,8,9,10}"
33-
# std: 17
34-
# - compiler.cxx: "clang++-{6.0,7,8,9,10}"
35-
# std: 20
25+
std: [11]
26+
include:
27+
- cxx: g++-5
28+
other_pkgs: g++-5
29+
- cxx: g++-6
30+
other_pkgs: g++-6
31+
- cxx: g++-7
32+
other_pkgs: g++-7
33+
- cxx: g++-8
34+
other_pkgs: g++-8
35+
- cxx: g++-9
36+
other_pkgs: g++-9
37+
- cxx: g++-10
38+
other_pkgs: g++-10
39+
- cxx: clang++-6.0
40+
other_pkgs: clang-6.0
41+
- cxx: clang++-7
42+
other_pkgs: clang-7
43+
- cxx: clang++-8
44+
other_pkgs: clang-8
45+
- cxx: clang++-9
46+
other_pkgs: clang-9
47+
- cxx: clang++-10
48+
other_pkgs: clang-10
49+
- cxx: clang++-10
50+
other_pkgs: clang-10
51+
std: 14
52+
- cxx: clang++-10
53+
other_pkgs: clang-10
54+
std: 17
55+
- cxx: clang++-10
56+
other_pkgs: clang-10
57+
std: 20
58+
- cxx: g++-10
59+
other_pkgs: g++-10
60+
std: 14
61+
- cxx: g++-10
62+
other_pkgs: g++-10
63+
std: 17
64+
- cxx: g++-10
65+
other_pkgs: g++-10
66+
std: 20
3667

3768
steps:
3869
- uses: actions/checkout@v4
@@ -41,25 +72,24 @@ jobs:
4172
run: |
4273
sudo apt-add-repository 'deb http://azure.archive.ubuntu.com/ubuntu/ bionic main'
4374
sudo apt-add-repository 'deb http://azure.archive.ubuntu.com/ubuntu/ bionic universe'
44-
if: ${{ matrix.compiler.cxx == 'g++-5' || matrix.compiler.cxx == 'g++-6' }}
75+
if: ${{ matrix.cxx == 'g++-5' || matrix.cxx == 'g++-6' }}
4576

4677
- name: Prepare environment
4778
run: |
4879
sudo apt-get update
49-
sudo apt-get install -y ninja-build ${{matrix.compiler.other_pkgs}}
80+
sudo apt-get install -y ninja-build ${{matrix.other_pkgs}}
5081
5182
- name: Configure CMake
5283
env:
53-
CXX: ${{matrix.compiler.cxx}}
84+
CXX: ${{matrix.cxx}}
5485
run: |
5586
cmake -B build \
56-
-DCMAKE_BUILD_TYPE=${{matrix.built_type}} \
87+
-DCMAKE_BUILD_TYPE=${{matrix.build_type}} \
5788
-DCMAKE_CXX_STANDARD=${{matrix.std}} \
5889
-DCMAKE_CXX_STANDARD_REQUIRED=ON \
5990
-DCMAKE_CXX_EXTENSIONS=OFF \
6091
-DRAPIDFUZZ_BUILD_TESTING=1 \
6192
-DRAPIDFUZZ_ENABLE_LINTERS=1 \
62-
-DRAPIDFUZZ_BUILD_FUZZERS=1 \
6393
-G Ninja
6494
6595
- name: Build
@@ -68,15 +98,5 @@ jobs:
6898

6999
- name: Test
70100
working-directory: build
71-
run: ctest -C ${{matrix.BUILD_TYPE}} --rerun-failed --output-on-failure -j `nproc`
101+
run: ctest -C ${{matrix.build_type}} --rerun-failed --output-on-failure -j `nproc`
72102

73-
- name: Fuzz Test
74-
working-directory: build
75-
run: |
76-
fuzzing/fuzz_lcs_similarity -max_total_time=30
77-
fuzzing/fuzz_levenshtein_distance -max_total_time=30
78-
fuzzing/fuzz_levenshtein_editops -max_total_time=30
79-
fuzzing/fuzz_indel_distance -max_total_time=30
80-
fuzzing/fuzz_indel_editops -max_total_time=30
81-
fuzzing/fuzz_osa_distance -max_total_time=30
82-
fuzzing/fuzz_damerau_levenshtein_distance -max_total_time=30

rapidfuzz/details/simd.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
/* RAPIDFUZZ_LTO_HACK is used to differentiate functions between different
77
* translation units to avoid warnings when using lto */
88
#ifndef RAPIDFUZZ_EXCLUDE_SIMD
9-
# if __AVX2__
9+
# if 0//__AVX2__
1010
# define RAPIDFUZZ_SIMD
1111
# define RAPIDFUZZ_AVX2
1212
# define RAPIDFUZZ_LTO_HACK 0

0 commit comments

Comments
 (0)