| 1 |
|
| 2 |
|
| 3 |
|
| 4 |
|
| 5 |
name: Constant-time tests |
| 6 |
permissions: |
| 7 |
contents: read |
| 8 |
on: |
| 9 |
workflow_call: |
| 10 |
workflow_dispatch: |
| 11 |
|
| 12 |
jobs: |
| 13 |
check-ct-varlat: |
| 14 |
|
| 15 |
|
| 16 |
|
| 17 |
name: CT test ${{ matrix.nix-shell }} ${{ matrix.system }} |
| 18 |
strategy: |
| 19 |
fail-fast: false |
| 20 |
max-parallel: 10 |
| 21 |
matrix: |
| 22 |
system: [ubuntu-latest, ubuntu-24.04-arm] |
| 23 |
nix-shell: |
| 24 |
- ci_valgrind-varlat_clang14 |
| 25 |
- ci_valgrind-varlat_clang15 |
| 26 |
- ci_valgrind-varlat_clang16 |
| 27 |
- ci_valgrind-varlat_clang17 |
| 28 |
- ci_valgrind-varlat_clang18 |
| 29 |
- ci_valgrind-varlat_clang19 |
| 30 |
- ci_valgrind-varlat_clang20 |
| 31 |
- ci_valgrind-varlat_clang21 |
| 32 |
- ci_valgrind-varlat_gcc48 |
| 33 |
- ci_valgrind-varlat_gcc49 |
| 34 |
- ci_valgrind-varlat_gcc7 |
| 35 |
- ci_valgrind-varlat_gcc11 |
| 36 |
- ci_valgrind-varlat_gcc12 |
| 37 |
- ci_valgrind-varlat_gcc13 |
| 38 |
- ci_valgrind-varlat_gcc14 |
| 39 |
- ci_valgrind-varlat_gcc15 |
| 40 |
runs-on: ${{ matrix.system }} |
| 41 |
steps: |
| 42 |
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 |
| 43 |
- name: Setup nix |
| 44 |
uses: ./.github/actions/setup-shell |
| 45 |
with: |
| 46 |
gh_token: ${{ secrets.GITHUB_TOKEN }} |
| 47 |
nix-shell: ${{ matrix.nix-shell }} |
| 48 |
nix-cache: true |
| 49 |
- name: Build and run test (-Oz) |
| 50 |
|
| 51 |
if: ${{ matrix.nix-shell != 'ci_valgrind-varlat_gcc48' && matrix.nix-shell != 'ci_valgrind-varlat_gcc49' && matrix.nix-shell != 'ci_valgrind-varlat_gcc7' && matrix.nix-shell != 'ci_valgrind-varlat_gcc11'}} |
| 52 |
uses: ./.github/actions/ct-test |
| 53 |
with: |
| 54 |
cflags: -Oz -DMLD_CONFIG_KEYGEN_PCT |
| 55 |
valgrind_flags: --variable-latency-errors=yes |
| 56 |
- name: Build and run test (-Os) |
| 57 |
uses: ./.github/actions/ct-test |
| 58 |
with: |
| 59 |
cflags: -Os -DMLD_CONFIG_KEYGEN_PCT |
| 60 |
valgrind_flags: --variable-latency-errors=yes |
| 61 |
- name: Build and run test (-O3) |
| 62 |
uses: ./.github/actions/ct-test |
| 63 |
with: |
| 64 |
cflags: -O3 -DMLD_CONFIG_KEYGEN_PCT |
| 65 |
valgrind_flags: --variable-latency-errors=yes |
| 66 |
- name: Build and run test (-Ofast) |
| 67 |
|
| 68 |
if: ${{ matrix.nix-shell != 'ci_valgrind-varlat_clang19' && matrix.nix-shell != 'ci_valgrind-varlat_clang20' && matrix.nix-shell != 'ci_valgrind-varlat_clang21'}} |
| 69 |
uses: ./.github/actions/ct-test |
| 70 |
with: |
| 71 |
cflags: -Ofast -DMLD_CONFIG_KEYGEN_PCT |
| 72 |
valgrind_flags: --variable-latency-errors=yes |
| 73 |
- name: Build and run test (-O3 -ffast-math) |
| 74 |
uses: ./.github/actions/ct-test |
| 75 |
with: |
| 76 |
cflags: -O3 -ffast-math -DMLD_CONFIG_KEYGEN_PCT |
| 77 |
valgrind_flags: --variable-latency-errors=yes |
| 78 |
- name: Build and run test (-O2) |
| 79 |
uses: ./.github/actions/ct-test |
| 80 |
with: |
| 81 |
cflags: -O2 -DMLD_CONFIG_KEYGEN_PCT |
| 82 |
valgrind_flags: --variable-latency-errors=yes |
| 83 |
- name: Build and run test (-O1) |
| 84 |
uses: ./.github/actions/ct-test |
| 85 |
with: |
| 86 |
cflags: -O1 -DMLD_CONFIG_KEYGEN_PCT |
| 87 |
valgrind_flags: --variable-latency-errors=yes |
| 88 |
- name: Build and run test (-O0) |
| 89 |
uses: ./.github/actions/ct-test |
| 90 |
with: |
| 91 |
cflags: -O0 -DMLD_CONFIG_KEYGEN_PCT |
| 92 |
valgrind_flags: --variable-latency-errors=yes |