88#
99# For more information, see https://github.com/haskell-CI/haskell-ci
1010#
11- # version: 0.19.20240402
11+ # version: 0.19.20240514
1212#
13- # REGENDATA ("0.19.20240402 ",["github","--project","cabal.bench.project","-o",".github/workflows/haskell-ci-bench.yml","--github-action-name","Benchmarks"])
13+ # REGENDATA ("0.19.20240514 ",["github","--project","cabal.bench.project","-o",".github/workflows/haskell-ci-bench.yml","--github-action-name","Benchmarks"])
1414#
1515name : Benchmarks
1616on :
@@ -27,19 +27,24 @@ jobs:
2727 timeout-minutes :
2828 60
2929 container :
30- image : buildpack-deps:bionic
30+ image : buildpack-deps:jammy
3131 continue-on-error : ${{ matrix.allow-failure }}
3232 strategy :
3333 matrix :
3434 include :
35+ - compiler : ghc-9.10.1
36+ compilerKind : ghc
37+ compilerVersion : 9.10.1
38+ setup-method : ghcup
39+ allow-failure : false
3540 - compiler : ghc-9.8.2
3641 compilerKind : ghc
3742 compilerVersion : 9.8.2
3843 setup-method : ghcup
3944 allow-failure : false
40- - compiler : ghc-9.6.4
45+ - compiler : ghc-9.6.5
4146 compilerKind : ghc
42- compilerVersion : 9.6.4
47+ compilerVersion : 9.6.5
4348 setup-method : ghcup
4449 allow-failure : false
4550 - compiler : ghc-9.4.8
6065 - compiler : ghc-9.0.1
6166 compilerKind : ghc
6267 compilerVersion : 9.0.1
63- setup-method : hvr-ppa
68+ setup-method : ghcup
6469 allow-failure : false
6570 - compiler : ghc-8.10.7
6671 compilerKind : ghc
@@ -70,51 +75,29 @@ jobs:
7075 - compiler : ghc-8.10.4
7176 compilerKind : ghc
7277 compilerVersion : 8.10.4
73- setup-method : hvr-ppa
78+ setup-method : ghcup
7479 allow-failure : false
7580 - compiler : ghc-8.8.3
7681 compilerKind : ghc
7782 compilerVersion : 8.8.3
78- setup-method : hvr-ppa
83+ setup-method : ghcup
7984 allow-failure : false
8085 - compiler : ghc-8.6.5
8186 compilerKind : ghc
8287 compilerVersion : 8.6.5
83- setup-method : hvr-ppa
84- allow-failure : false
85- - compiler : ghc-8.4.4
86- compilerKind : ghc
87- compilerVersion : 8.4.4
88- setup-method : hvr-ppa
89- allow-failure : false
90- - compiler : ghc-8.2.2
91- compilerKind : ghc
92- compilerVersion : 8.2.2
93- setup-method : hvr-ppa
88+ setup-method : ghcup
9489 allow-failure : false
9590 fail-fast : false
9691 steps :
9792 - name : apt
9893 run : |
9994 apt-get update
10095 apt-get install -y --no-install-recommends gnupg ca-certificates dirmngr curl git software-properties-common libtinfo5
101- if [ "${{ matrix.setup-method }}" = ghcup ]; then
102- mkdir -p "$HOME/.ghcup/bin"
103- curl -sL https://downloads.haskell.org/ghcup/0.1.20.0/x86_64-linux-ghcup-0.1.20.0 > "$HOME/.ghcup/bin/ghcup"
104- chmod a+x "$HOME/.ghcup/bin/ghcup"
105- "$HOME/.ghcup/bin/ghcup" config add-release-channel https://raw.githubusercontent.com/haskell/ghcup-metadata/master/ghcup-prereleases-0.0.8.yaml;
106- "$HOME/.ghcup/bin/ghcup" install ghc "$HCVER" || (cat "$HOME"/.ghcup/logs/*.* && false)
107- "$HOME/.ghcup/bin/ghcup" install cabal 3.10.2.0 || (cat "$HOME"/.ghcup/logs/*.* && false)
108- else
109- apt-add-repository -y 'ppa:hvr/ghc'
110- apt-get update
111- apt-get install -y "$HCNAME"
112- mkdir -p "$HOME/.ghcup/bin"
113- curl -sL https://downloads.haskell.org/ghcup/0.1.20.0/x86_64-linux-ghcup-0.1.20.0 > "$HOME/.ghcup/bin/ghcup"
114- chmod a+x "$HOME/.ghcup/bin/ghcup"
115- "$HOME/.ghcup/bin/ghcup" config add-release-channel https://raw.githubusercontent.com/haskell/ghcup-metadata/master/ghcup-prereleases-0.0.8.yaml;
116- "$HOME/.ghcup/bin/ghcup" install cabal 3.10.2.0 || (cat "$HOME"/.ghcup/logs/*.* && false)
117- fi
96+ mkdir -p "$HOME/.ghcup/bin"
97+ curl -sL https://downloads.haskell.org/ghcup/0.1.20.0/x86_64-linux-ghcup-0.1.20.0 > "$HOME/.ghcup/bin/ghcup"
98+ chmod a+x "$HOME/.ghcup/bin/ghcup"
99+ "$HOME/.ghcup/bin/ghcup" install ghc "$HCVER" || (cat "$HOME"/.ghcup/logs/*.* && false)
100+ "$HOME/.ghcup/bin/ghcup" install cabal 3.10.2.0 || (cat "$HOME"/.ghcup/logs/*.* && false)
118101 env :
119102 HCKIND : ${{ matrix.compilerKind }}
120103 HCNAME : ${{ matrix.compiler }}
@@ -126,22 +109,13 @@ jobs:
126109 echo "CABAL_DIR=$HOME/.cabal" >> "$GITHUB_ENV"
127110 echo "CABAL_CONFIG=$HOME/.cabal/config" >> "$GITHUB_ENV"
128111 HCDIR=/opt/$HCKIND/$HCVER
129- if [ "${{ matrix.setup-method }}" = ghcup ]; then
130- HC=$("$HOME/.ghcup/bin/ghcup" whereis ghc "$HCVER")
131- HCPKG=$(echo "$HC" | sed 's#ghc$#ghc-pkg#')
132- HADDOCK=$(echo "$HC" | sed 's#ghc$#haddock#')
133- echo "HC=$HC" >> "$GITHUB_ENV"
134- echo "HCPKG=$HCPKG" >> "$GITHUB_ENV"
135- echo "HADDOCK=$HADDOCK" >> "$GITHUB_ENV"
136- echo "CABAL=$HOME/.ghcup/bin/cabal-3.10.2.0 -vnormal+nowrap" >> "$GITHUB_ENV"
137- else
138- HC=$HCDIR/bin/$HCKIND
139- echo "HC=$HC" >> "$GITHUB_ENV"
140- echo "HCPKG=$HCDIR/bin/$HCKIND-pkg" >> "$GITHUB_ENV"
141- echo "HADDOCK=$HCDIR/bin/haddock" >> "$GITHUB_ENV"
142- echo "CABAL=$HOME/.ghcup/bin/cabal-3.10.2.0 -vnormal+nowrap" >> "$GITHUB_ENV"
143- fi
144-
112+ HC=$("$HOME/.ghcup/bin/ghcup" whereis ghc "$HCVER")
113+ HCPKG=$(echo "$HC" | sed 's#ghc$#ghc-pkg#')
114+ HADDOCK=$(echo "$HC" | sed 's#ghc$#haddock#')
115+ echo "HC=$HC" >> "$GITHUB_ENV"
116+ echo "HCPKG=$HCPKG" >> "$GITHUB_ENV"
117+ echo "HADDOCK=$HADDOCK" >> "$GITHUB_ENV"
118+ echo "CABAL=$HOME/.ghcup/bin/cabal-3.10.2.0 -vnormal+nowrap" >> "$GITHUB_ENV"
145119 HCNUMVER=$(${HC} --numeric-version|perl -ne '/^(\d+)\.(\d+)\.(\d+)(\.(\d+))?$/; print(10000 * 1ドル + 100 * 2ドル + (3ドル == 0 ? 5ドル != 1 : 3ドル))')
146120 echo "HCNUMVER=$HCNUMVER" >> "$GITHUB_ENV"
147121 echo "ARG_TESTS=--enable-tests" >> "$GITHUB_ENV"
@@ -198,7 +172,7 @@ jobs:
198172 chmod a+x $HOME/.cabal/bin/cabal-plan
199173 cabal-plan --version
200174 - name : checkout
201- uses : actions/checkout@v3
175+ uses : actions/checkout@v4
202176 with :
203177 path : source
204178 - name : initial cabal.project for sdist
@@ -226,15 +200,15 @@ jobs:
226200 echo " ghc-options: -Werror=missing-methods" >> cabal.project
227201 cat >> cabal.project <<EOF
228202 EOF
229- $HCPKG list --simple-output --names-only | perl -ne 'for (split /\s+/) { print "constraints: $_ installed\n" unless /^(hashable-bench)$/; }' >> cabal.project.local
203+ $HCPKG list --simple-output --names-only | perl -ne 'for (split /\s+/) { print "constraints: any. $_ installed\n" unless /^(hashable-bench)$/; }' >> cabal.project.local
230204 cat cabal.project
231205 cat cabal.project.local
232206 - name : dump install plan
233207 run : |
234208 $CABAL v2-build $ARG_COMPILER $ARG_TESTS $ARG_BENCH --dry-run all
235209 cabal-plan
236210 - name : restore cache
237- uses : actions/cache/restore@v3
211+ uses : actions/cache/restore@v4
238212 with :
239213 key : ${{ runner.os }}-${{ matrix.compiler }}-${{ github.sha }}
240214 path : ~/.cabal/store
@@ -271,18 +245,18 @@ jobs:
271245 if [ $((HCNUMVER >= 90200)) -ne 0 ] ; then $CABAL v2-build $ARG_COMPILER --enable-tests --disable-benchmarks --constraint='filepath ^>=1.5.2.0' all ; fi
272246 - name : constraint set filepath-1.4.100.0
273247 run : |
274- $ CABAL v2-build $ARG_COMPILER --enable-tests --disable-benchmarks --constraint='filepath ^>=1.4.100.0' all --dry-run
275- cabal-plan topo | sort
276- $ CABAL v2-build $ARG_COMPILER --enable-tests --disable-benchmarks --constraint='filepath ^>=1.4.100.0' --dependencies-only -j2 all
277- $ CABAL v2-build $ARG_COMPILER --enable-tests --disable-benchmarks --constraint='filepath ^>=1.4.100.0' all
248+ if [ $((HCNUMVER < 91000)) -ne 0 ] ; then $ CABAL v2-build $ARG_COMPILER --enable-tests --disable-benchmarks --constraint='filepath ^>=1.4.100.0' all --dry-run ; fi
249+ if [ $((HCNUMVER < 91000)) -ne 0 ] ; then cabal-plan topo | sort ; fi
250+ if [ $((HCNUMVER < 91000)) -ne 0 ] ; then $ CABAL v2-build $ARG_COMPILER --enable-tests --disable-benchmarks --constraint='filepath ^>=1.4.100.0' --dependencies-only -j2 all ; fi
251+ if [ $((HCNUMVER < 91000)) -ne 0 ] ; then $ CABAL v2-build $ARG_COMPILER --enable-tests --disable-benchmarks --constraint='filepath ^>=1.4.100.0' all ; fi
278252 - name : constraint set random-initial-seed
279253 run : |
280254 $CABAL v2-build $ARG_COMPILER --disable-tests --disable-benchmarks --constraint='hashable +random-initial-seed' all --dry-run
281255 cabal-plan topo | sort
282256 $CABAL v2-build $ARG_COMPILER --disable-tests --disable-benchmarks --constraint='hashable +random-initial-seed' --dependencies-only -j2 all
283257 $CABAL v2-build $ARG_COMPILER --disable-tests --disable-benchmarks --constraint='hashable +random-initial-seed' all
284258 - name : save cache
285- uses : actions/cache/save@v3
259+ uses : actions/cache/save@v4
286260 if : always()
287261 with :
288262 key : ${{ runner.os }}-${{ matrix.compiler }}-${{ github.sha }}
0 commit comments