summaryrefslogtreecommitdiff
path: root/.github/workflows/testsuite.yml
blob: 92228e7475a89bb50ac0558eae2a204e4d5220d3 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
name: testsuite

on:
  push:
    branches:
      - "**"
    tags-ignore:
      - "*"
  pull_request:

# I don't think that we can (safely) set TEST_JOBS=2 in the global environment,
# because on Win32 the various Makefile's `test` target is actually ./harness,
# and it would (attempt to) honour the $ENV{TEST_JOBS} setting. This won't end
# nicely as unlike BSD (etc), Win32 sockets can drop data at process exit, which
# would cause missing TAP and hence spurious test failures.

env:
  PERL_SKIP_TTY_TEST: 1
  CONTINUOUS_INTEGRATION: 1

jobs:
  #  ___           _         ___       __                    _   _
  # / __|_ __  ___| |_____  |_ _|_ _  / _|___ _ _ _ __  __ _| |_(_)___ _ _  ___
  # \__ \ '  \/ _ \ / / -_)  | || ' \|  _/ _ \ '_| '  \/ _` |  _| / _ \ ' \(_-<
  # |___/_|_|_\___/_\_\___| |___|_||_|_| \___/_| |_|_|_\__,_|\__|_\___/_||_/__/

  authors:
    runs-on: ubuntu-latest
    if: ( github.event.pull_request.head.repo.full_name == 'Perl/perl5' || github.repository == 'Perl/perl5' ) && github.base_ref != ''
    continue-on-error: true

    steps:
      - name: Dump GitHub context
        env:
          GITHUB_CONTEXT: ${{ toJson(github) }}
        run: echo "$GITHUB_CONTEXT"
      - uses: actions/checkout@v2
        with:
          fetch-depth: 1000
      - name: git setup
        run: |
          echo "Pull request authors"
          echo "# git merge-base origin/${BASE_REF} HEAD"
          git config diff.renameLimit 999999
          git fetch --depth=1000 origin ${BASE_REF}
        env:
          BASE_REF: ${{ github.base_ref }}
      - name: Involved authors
        run: |
          git log --pretty=format:"Author: %an <%ae>" origin/${BASE_REF}...${SHA}^2 | sort -u
        env:
          BASE_REF: ${{ github.base_ref }}
          SHA: ${{ github.sha }}

  #  ___            _ _           ___ _           _
  # / __| __ _ _ _ (_) |_ _  _   / __| |_  ___ __| |__
  # \__ \/ _` | ' \| |  _| || | | (__| ' \/ -_) _| / /
  # |___/\__,_|_||_|_|\__|\_, |  \___|_||_\___\__|_\_\
  #                       |__/
  # ascii art small font from https://ascii.co.uk/text

  # "sanity_check" tests -Dusethreads without -DDEBUGGING
  # "linux-i386" tests -Uusethreads without -DDEBUGGING
  # All builds in the "linux" matrix test with -DDEBUGGING
  #
  # "sanity_check" sets `fetch-depth: 0` so that it does a git clone with full
  # history, and hence can run t/porting/cmp_version.t etc
  # The git-related tests require full history, but we only need to run them
  # once (they aren't platform specific).
  # Hence leave the others with the default setting (1), which performs a
  # shallow clone. In these shallow checkouts, the git related porting tests
  # skip (or rapidly pass), but they won't fail spuriously.

  sanity_check:
    name: "Sanity: Linux -Dusethreads"
    runs-on: ubuntu-latest
    timeout-minutes: 120

    outputs:
      run_all_jobs: ${{ steps.check_extended_testing.outputs.run_all_jobs }}

    steps:
      - name: Dump GitHub context
        env:
          GITHUB_CONTEXT: ${{ toJson(github) }}
        run: echo "$GITHUB_CONTEXT"
      - name: Install System dependencies
        run: |
          sudo apt-get update
          sudo apt-get install -y libgdbm-dev libdb-dev
      - uses: actions/checkout@v2
        with:
          fetch-depth: 0
      - name: git cfg + fetch tags
        run: |
          git config diff.renameLimit 999999
          git fetch --depth=1 origin +refs/tags/*:refs/tags/*
      - name: Configure
        run: |
          ./Configure -des -Dusedevel ${CONFIGURE_ARGS} -Dprefix="$HOME/perl-blead"
        env:
          CONFIGURE_ARGS: "-Dusethreads"
      - name: Build
        run: |
          make -j2 test_prep
      - name: Show Config
        run: |
          ./perl -Ilib -V
          ./perl -Ilib -e 'use Config; print Config::config_sh'
      - name: Run Tests
        run: |
          TEST_JOBS=2 ./perl t/harness

      # Set a variable for dependent jobs to signal if full testsuite is enabled
      - name: "Check if EXTENDED_TESTING is set"
        id: check_extended_testing
        env:
          EXTENDED_TESTING: ${{ secrets.EXTENDED_TESTING }}
          CURRENT_REPOSITORY: ${{ github.repository }}
        run: |
          if [[ -z "${EXTENDED_TESTING}" && "${CURRENT_REPOSITORY}" != 'Perl/perl5' ]]; then
            echo "Skipping extended test jobs."
            echo "::set-output name=run_all_jobs::false"
          else
            echo "Running all test jobs"
            echo "::set-output name=run_all_jobs::true"
          fi

  #  _ _
  # | (_)_ _ _  ___ __
  # | | | ' \ || \ \ /
  # |_|_|_||_\_,_/_\_\

  linux:
    runs-on: ubuntu-latest
    timeout-minutes: 120
    needs: sanity_check
    if: needs.sanity_check.outputs.run_all_jobs == 'true'

    strategy:
      fail-fast: false
      matrix:
        # exercise a variety of build options
        # threads often cause build issues
        CONFIGURE_ARGS:
          - "-Uusethreads"
          #- "-Dusethreads" # already tested above by sanity_check
          #- "-Duseshrplib -Dusesitecustomize -Duselongdouble" # tested below by install
          - "-Duseshrplib -Dusequadmath -Dusecbacktrace -Dusethreads"
          - "-Duserelocatableinc"
          - "-Dcc='clang'"

    steps:
      - name: Install System dependencies
        run: |
          sudo apt-get update
          sudo apt-get install -y libgdbm-dev libdb-dev
      - uses: actions/checkout@v2
      - name: git cfg + fetch tags
        run: |
          git config diff.renameLimit 999999
          git fetch --depth=1 origin +refs/tags/*:refs/tags/*
      - name: Configure
        run: |
          ./Configure -des -Dusedevel ${{ matrix.CONFIGURE_ARGS }} -Dprefix="$HOME/perl-blead" -DDEBUGGING
      - name: Build
        run: |
          MALLOC_PERTURB_=254 MALLOC_CHECK_=3 make -j2 test_prep
      - name: Show Config
        run: |
          LD_LIBRARY_PATH=`pwd` ./perl -Ilib -V
          LD_LIBRARY_PATH=`pwd` ./perl -Ilib -e 'use Config; print Config::config_sh'
      - name: Run Tests
        run: |
          LD_LIBRARY_PATH=`pwd` MALLOC_PERTURB_=254 MALLOC_CHECK_=3 TEST_JOBS=2 ./perl t/harness
      - name: git clean
        run: |
          git clean -dxf
      - name: manicheck
        run: |
          perl Porting/manicheck --exitstatus

  #  _ _                       _ _____  ___   __
  # | (_)_ __  _   ___  __    (_)___ / ( _ ) / /_
  # | | | '_ \| | | \ \/ /____| | |_ \ / _ \| '_ \
  # | | | | | | |_| |>  <_____| |___) | (_) | (_) |
  # |_|_|_| |_|\__,_/_/\_\    |_|____/ \___/ \___/

  linux-i386:
    name: "linux i386/ubuntu"
    runs-on: ubuntu-latest
    timeout-minutes: 120
    needs: sanity_check
    if: needs.sanity_check.outputs.run_all_jobs == 'true'

    # https://hub.docker.com/r/i386/ubuntu/
    container:
      image: i386/ubuntu:latest

    strategy:
      fail-fast: false
      matrix:
        CONFIGURE_ARGS:
          - "-Dusedevel"

    steps:
      - name: Install System dependencies
        run: |
          apt-get update
          apt-get install -y build-essential git-core libgdbm-dev libdb-dev
      # actions/checkout@v2 doesn't work in a container, so we use v1.
      - uses: actions/checkout@v1
      - name: fix git remote credential
        run: git remote set-url origin "https://$GITHUB_ACTOR:${{ secrets.GITHUB_TOKEN }}@github.com/$GITHUB_REPOSITORY"
      - name: git cfg + fetch tags
        run: |
          git config diff.renameLimit 999999
          git fetch --depth=1 origin +refs/tags/*:refs/tags/*
      - name: Configure
        run: |
          ./Configure -des -Dusedevel ${{ matrix.CONFIGURE_ARGS }} -Dprefix="$HOME/perl-blead"
      - name: Build
        run: |
          MALLOC_PERTURB_=254 MALLOC_CHECK_=3 make -j2
      - name: Show Config
        run: |
          LD_LIBRARY_PATH=`pwd` ./perl -Ilib -V
          LD_LIBRARY_PATH=`pwd` ./perl -Ilib -e 'use Config; print Config::config_sh'
      # Leaving this as `make test` so that we test the `test` target on regular
      # Linux.
      # linux-i386 is just one job (not a matrix)
      - name: Run Tests
        run: |
          MALLOC_PERTURB_=254 MALLOC_CHECK_=3 make -j2 test

  #                  _          _           _        _ _
  #  _ __ ___   __ _| | _____  (_)_ __  ___| |_ __ _| | |
  # | '_ ` _ \ / _` | |/ / _ \ | | '_ \/ __| __/ _` | | |
  # | | | | | | (_| |   <  __/ | | | | \__ \ || (_| | | |
  # |_| |_| |_|\__,_|_|\_\___| |_|_| |_|___/\__\__,_|_|_|

  install:
    runs-on: ubuntu-latest
    timeout-minutes: 120
    needs: sanity_check
    if: needs.sanity_check.outputs.run_all_jobs == 'true'

    steps:
      - name: Install System dependencies
        run: |
          sudo apt-get update
          sudo apt-get install -y libgdbm-dev libdb-dev
      - uses: actions/checkout@v2
      - name: git cfg + fetch tags
        run: |
          git config diff.renameLimit 999999
          git fetch --depth=1 origin +refs/tags/*:refs/tags/*
      - name: Configure
        run: |
          ./Configure -des -Dusedevel -Duseshrplib -Dusesitecustomize -Duselongdouble -Dprefix="$HOME/perl-blead" -DDEBUGGING
      - name: Build
        run: |
          MALLOC_PERTURB_=254 MALLOC_CHECK_=3 make -j2
      - name: Show Config
        run: |
          LD_LIBRARY_PATH=`pwd` ./perl -Ilib -V
          LD_LIBRARY_PATH=`pwd` ./perl -Ilib -e 'use Config; print Config::config_sh'
      - name: Run Tests
        run: |
          MALLOC_PERTURB_=254 MALLOC_CHECK_=3 TEST_JOBS=2 make -j2 test_harness
      - name: Install
        run: |
          MALLOC_PERTURB_=254 MALLOC_CHECK_=3 TEST_JOBS=2 make -j2 install
      # This will only pass if libperl.so and Config.pm are correctly installed:
      - name: Show Install
        run: |
          ./perl -V
      # This can't run in parallel
      - name: distclean
        run: |
          MALLOC_PERTURB_=254 MALLOC_CHECK_=3 make distclean
      - name: manicheck
        run: |
          perl Porting/manicheck --exitstatus

  #                 ___  ___
  #  _ __  __ _ __ / _ \/ __|
  # | '  \/ _` / _| (_) \__ \
  # |_|_|_\__,_\__|\___/|___/

  smoke-macos-catalina-xcode12:
    name: "macOS (catalina) xcode 12"
    runs-on: macos-10.15
    timeout-minutes: 120
    needs: sanity_check
    if: needs.sanity_check.outputs.run_all_jobs == 'true'

    strategy:
      fail-fast: false
      matrix:
        CONFIGURE_ARGS:
          - "-Uusethreads"
          - "-Duseithreads -Duseshrplib"

    steps:
      - uses: actions/checkout@v2
      - name: Configure
        run: |
          export SDK=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk
          sh ./Configure -des -Dusedevel ${{ matrix.CONFIGURE_ARGS }}
      - name: Build
        run: |
          make -j2 test_prep
      - name: Show Config
        run: |
          ./perl -Ilib -V
          ./perl -Ilib -e 'use Config; print Config::config_sh'
      - name: Run Tests
        run: |
          TEST_JOBS=2 ./perl t/harness

  #         _         _
  # __ __ _(_)_ _  __| |_____ __ _____
  # \ V  V / | ' \/ _` / _ \ V  V (_-<
  #  \_/\_/|_|_||_\__,_\___/\_/\_//__/

  windows-msvc142:
    name: "Windows msvc142"
    runs-on: windows-latest
    timeout-minutes: 120
    needs: sanity_check
    if: needs.sanity_check.outputs.run_all_jobs == 'true'

    steps:
      - run: git config --global core.autocrlf false
      - uses: actions/checkout@v2
      #- name: Install clcache
      #  shell: cmd
      #  run: |
      #    curl -L https://github.com/frerich/clcache/releases/download/v4.2.0/clcache.4.2.0.nupkg --output clcache.4.2.0.nupkg
      #    choco install clcache --source=.
      #- name: find home directory
      #  shell: cmd
      #  run: |
      #    set
      #- name: C compiler cache
      #  id: clcache
      #  uses: actions/cache@v1
      #  with:
      #    path: $HOME\clcache
      #    key: ${{ runner.os }}-x64
      #- name: Set up Perl build environment
      #  # pushd "C:\Program Files (x86)\Microsoft Visual Studio\Installer\"
      #  # for /f "delims=" %%x in ('.\vswhere.exe -latest -property InstallationPath') do set VSPATH=%%x
      #  # popd
      #  # call "%VSPATH%\VC\Auxiliary\Build\vcvarsall.bat" x64
      #  #run: |
      - name: Build
        shell: cmd
        run: |
          call "C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\VC\Auxiliary\Build\vcvarsall.bat" x64
          cd win32
          nmake CCTYPE=MSVC142
      - name: Show Config
        shell: cmd
        run: |
          .\perl.exe -V
          .\perl.exe -e "use Config; print Config::config_sh"
      - name: Run Tests
        shell: cmd
        run: |
          call "C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\VC\Auxiliary\Build\vcvarsall.bat" x64
          cd win32
          nmake CCTYPE=MSVC142 test

  #            _                       __   _  _
  #  _ __ ___ (_)_ __   __ ___      __/ /_ | || |
  # | '_ ` _ \| | '_ \ / _` \ \ /\ / / '_ \| || |_
  # | | | | | | | | | | (_| |\ V  V /| (_) |__   _|
  # |_| |_| |_|_|_| |_|\__, | \_/\_/  \___/   |_|
  #                    |___/

  mingw64:
    name: "Windows mingw64"
    runs-on: windows-latest
    timeout-minutes: 120
    needs: sanity_check
    if: needs.sanity_check.outputs.run_all_jobs == 'true'

    steps:
      - run: git config --global core.autocrlf false
      - uses: actions/checkout@v2
      - name: Set up Perl build environment
        run: |
          # skip installing perl if it is already installed.
          if (!(Test-Path "C:\strawberry\perl\bin")) {
            choco install strawberryperl
          }
          echo @"
          C:\strawberry\c\bin
          C:\strawberry\perl\site\bin
          C:\strawberry\perl\bin
          "@ |
            Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append
      - name: Host perl -V
        run: perl -V
      - name: gcc --version
        run: gcc --version
      - name: Build
        shell: cmd
        run: |
          cd win32
          gmake CCHOME=C:\strawberry\c -f GNUMakefile -j2
      - name: Show Config
        shell: cmd
        run: |
          .\perl.exe -V
          .\perl.exe -e "use Config; print Config::config_sh"
      - name: Run Tests
        shell: cmd
        run: |
          cd win32
          set HARNESS_OPTIONS=j2
          gmake CCHOME=C:\strawberry\c -f GNUMakefile test

  #                            _
  #   ___ _   _  __ ___      _(_)_ __
  #  / __| | | |/ _` \ \ /\ / / | '_ \
  # | (__| |_| | (_| |\ V  V /| | | | |
  #  \___|\__, |\__, | \_/\_/ |_|_| |_|
  #       |___/ |___/

  cygwin:
    name: "cygwin"
    runs-on: windows-latest
    timeout-minutes: 120
    needs: sanity_check
    if: needs.sanity_check.outputs.run_all_jobs == 'true'

    steps:
      # we use Cygwin git, so no need to configure git here.

      - name: Set up Cygwin
        shell: cmd
        run: |
          choco install cygwin --params="/InstallDir:%GITHUB_WORKSPACE%\cygwin"
          choco install cyg-get
          cyg-get cygwin-devel gcc-core gcc gcc-g++ make cygwin64-w32api-headers ^
                  binutils libtool git ccache lib libgdbm-devel libdb-devel
      - name: Check out using Cygwin git, to ensure correct file permissions
        env:
          GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
        shell: cmd
        run: |
          path %GITHUB_WORKSPACE%\cygwin\bin;%GITHUB_WORKSPACE%\cygwin\usr\bin
          sh -c "git config --global core.autocrlf false"
          sh -c "mkdir -p ~; cd ~; git clone -qn \"https://$GITHUB_ACTOR:$GITHUB_TOKEN@github.com/$GITHUB_REPOSITORY\" work ; cd work ; if [ \"$GITHUB_EVENT_NAME\" = pull_request ] ; then git fetch origin \"$GITHUB_REF\" && git checkout FETCH_HEAD ; else  git checkout \"$GITHUB_SHA\" ; fi"
      - name: Configure
        shell: cmd
        run: |
          path %GITHUB_WORKSPACE%\cygwin\bin;%GITHUB_WORKSPACE%\cygwin\usr\bin
          sh -c "cd ~/work; ./Configure -des -Dusedevel -Doptimize=-g -DDEBUGGING"
      - name: Build
        shell: cmd
        run: |
          path %GITHUB_WORKSPACE%\cygwin\bin;%GITHUB_WORKSPACE%\cygwin\usr\bin
          sh -c "cd ~/work; make -j2 test_prep"
      - name: Show Config
        shell: cmd
        run: |
          path %GITHUB_WORKSPACE%\cygwin\bin;%GITHUB_WORKSPACE%\cygwin\usr\bin
          sh -c "cd ~/work; ./perl -Ilib -V; ./perl -Ilib -e 'use Config; print Config::config_sh'"
      - name: Run Tests
        shell: cmd
        # Descend far enough down the cygwin yak warren, and one discovers that
        # hints/cygwin.sh sets ldlibpthname=PATH
        # Meaning that the Makefile variable LDLIBPTH is "PATH=..."
        # Meaning that the command to invoke ./runtests is PATH=... ./perl.exe
        # *Not* LD_LIBRARY_PATH or anything conventionally unix-like
        #
        # Cygwin is the slowest CI test. Breaking the abstractions described
        # above/committing this DRY violation means that we avoid needing to
        # `make -j2 test` to invoke t/TEST, and avoiding that likely saves us
        # about 40 seconds, which is nearly 1% of the total wallclock time for
        # complete all CI runs.
        run: |
          path %GITHUB_WORKSPACE%\cygwin\bin;%GITHUB_WORKSPACE%\cygwin\usr\bin
          sh -c "cd ~/work; PATH=`pwd`:.:$PATH ./perl.exe t/TEST"

  #            _       _ _            _
  #  _ __ ___ (_)_ __ (_) |_ ___  ___| |_
  # | '_ ` _ \| | '_ \| | __/ _ \/ __| __|
  # | | | | | | | | | | | ||  __/\__ \ |_
  # |_| |_| |_|_|_| |_|_|\__\___||___/\__|

  miniperl:
    name: "minitest"
    runs-on: ubuntu-latest
    timeout-minutes: 120
    needs: sanity_check
    if: needs.sanity_check.outputs.run_all_jobs == 'true'

    outputs:
      run_all_jobs: ${{ steps.check_extended_testing.outputs.run_all_jobs }}

    steps:
      - name: Dump GitHub context
        env:
          GITHUB_CONTEXT: ${{ toJson(github) }}
        run: echo "$GITHUB_CONTEXT"
      - name: Install System dependencies
        run: |
          sudo apt-get update
          sudo apt-get install -y libgdbm-dev libdb-dev
      - uses: actions/checkout@v2
      - name: git cfg + fetch tags
        run: |
          git config diff.renameLimit 999999
          git fetch --depth=1 origin +refs/tags/*:refs/tags/*
      - name: manicheck
        run: |
          perl Porting/manicheck --exitstatus
      - name: Configure
        run: |
          ./Configure -des -Dusedevel -Dprefix="$HOME/perl-blead"
      - name: Build
        run: |
          make -j2 minitest_prep
      - name: Show Config
        run: |
          ./miniperl -Ilib -V
          ./miniperl -Ilib -e 'use Config; print Config::config_sh'
      - name: Run Tests
        run: |
          make minitest_notty

  #     _    ____    _    _   _
  #    / \  / ___|  / \  | \ | |
  #   / _ \ \___ \ / _ \ |  \| |
  #  / ___ \ ___) / ___ \| |\  |
  # /_/   \_\____/_/   \_\_| \_|

  # Life is pain, highness. Anyone who says differently is selling something.

  ASAN:
    name: "ASAN"
    runs-on: ubuntu-latest
    timeout-minutes: 120
    needs: sanity_check
    if: needs.sanity_check.outputs.run_all_jobs == 'true'

    strategy:
      matrix:
        # -DPURIFY disables arenas and mallocs everything individually. With
        # ASAN or similar it's the real torture test. However, we also need to
        # test that the arena code doesn't have any goofs.
        CONFIGURE_ARGS:
          - "-Accflags=-DPURIFY"
          - "-DDEBUGGING"
          - "-Dusethreads"

    steps:
      - name: Install System dependencies
        run: |
          sudo apt-get update
          sudo apt-get install -y libgdbm-dev libdb-dev
      - uses: actions/checkout@v2
      - name: git cfg + fetch tags
        run: |
          git config diff.renameLimit 999999
          git fetch --depth=1 origin +refs/tags/*:refs/tags/*
      - name: Configure
        run: |
          ./Configure -des -Dusedevel -Dcc="clang -fsanitize=address" -Dld="clang -fsanitize=address" ${{ matrix.CONFIGURE_ARGS }} -Dprefix="$HOME/perl-blead"
      - name: Build
        run: |
          PERL_DESTRUCT_LEVEL=2 make -j2 test_prep
      - name: Show Config
        run: |
          ASAN_OPTIONS=detect_leaks=0 ./perl -Ilib -V
          ASAN_OPTIONS=detect_leaks=0 ./perl -Ilib -e 'use Config; print Config::config_sh'
      - name: Run Tests
        # LeakSanitizer is disabled because it randomly crashes, see [gh #19189]
        run: |
          ASAN_OPTIONS=detect_leaks=0 PERL_DESTRUCT_LEVEL=2 TEST_JOBS=2 ./perl t/harness

  #  ____  _____ ____  _        _   _ _   _ ___ ____ ___  ____  _____
  # |  _ \| ____|  _ \| |      | | | | \ | |_ _/ ___/ _ \|  _ \| ____|
  # | |_) |  _| | |_) | |      | | | |  \| || | |  | | | | | | |  _|
  # |  __/| |___|  _ <| |___   | |_| | |\  || | |__| |_| | |_| | |___
  # |_|   |_____|_| \_\_____|___\___/|_| \_|___\____\___/|____/|_____|
  #                        |_____|

  # To the pain!

  PERL_UNICODE:
    name: "PERL_UNICODE"
    runs-on: ubuntu-latest
    timeout-minutes: 120
    needs: sanity_check
    if: needs.sanity_check.outputs.run_all_jobs == 'true'

    strategy:
      matrix:
        # There are many many combinations we *could* test. These two are likely
        # to give the best overview - "basic sanity" and "everything maxed out"
        CONFIGURE_ARGS:
          - "-Uusethreads"
          - "-Dusethreads -Accflags=-DPURIFY -Dcc='gcc -fsanitize=address' -Dld='gcc -fsanitize=address'"

    steps:
      - name: Install System dependencies
        run: |
          sudo apt-get update
          sudo apt-get install -y libgdbm-dev libdb-dev
      - uses: actions/checkout@v2
      - name: git cfg + fetch tags
        run: |
          git config diff.renameLimit 999999
          git fetch --depth=1 origin +refs/tags/*:refs/tags/*
      - name: Show Locales
        run: locale -a
      - name: Configure
        run: |
          ./Configure -des -Dusedevel  ${{ matrix.CONFIGURE_ARGS }} -Dprefix="$HOME/perl-blead"
      - name: Build
        run: |
          LC_ALL=en_US.UTF-8 PERL_UNICODE="" PERL_DESTRUCT_LEVEL=2 make -j2 test_prep
      - name: Show Config
        run: |
          ASAN_OPTIONS=detect_leaks=0 ./perl -Ilib -V
          ASAN_OPTIONS=detect_leaks=0 ./perl -Ilib -e 'use Config; print Config::config_sh'
      - name: Run Tests
        # LeakSanitizer is disabled because it randomly crashes, see [gh #19189]
        run: |
          ASAN_OPTIONS=detect_leaks=0 PERL_DESTRUCT_LEVEL=2 LC_ALL=en_US.UTF-8 PERL_UNICODE="" TEST_JOBS=2 ./perl t/harness