summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlp Mestanogullari <alp@well-typed.com>2019-11-08 11:49:23 -0500
committerBen Gamari <ben@smart-cactus.org>2019-11-11 08:49:01 -0500
commit644334289eea0dd87380744a271d3b1d27902abb (patch)
treedabcaec0301e5893cfc07f2c93bd7894e792ceac
parent049d9ae08821fbfcadb2be708f57143ec0efd73b (diff)
downloadhaskell-644334289eea0dd87380744a271d3b1d27902abb.tar.gz
hadrian: export METRICS_FILE to make it accessible to perf notes script
This addresses #17456 and also fixes the --metrics-file argument that Hadrian passes to the testsuite driver.
-rw-r--r--.gitlab-ci.yml6
-rw-r--r--hadrian/src/Settings/Builders/RunTest.hs3
2 files changed, 4 insertions, 5 deletions
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 00355c33da..cc80845e81 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -204,13 +204,13 @@ lint-release-changelogs:
- cd _build/bindist/ghc-*/ && ./configure --prefix=$TOP/_build/install && make install && cd ../../../
- |
# Prepare to push git notes.
- METRICS_FILE=$CI_PROJECT_DIR/performance-metrics.tsv
+ export METRICS_FILE=$CI_PROJECT_DIR/performance-metrics.tsv
git config user.email "ben+ghc-ci@smart-cactus.org"
git config user.name "GHC GitLab CI"
- - hadrian/build.cabal.sh --flavour=$FLAVOUR -j`mk/detect-cpu-count.sh` --docs=no-sphinx test --summary-junit=./junit.xml --test-compiler=$TOP/_build/install/bin/ghc || (METRICS_FILE=$METRICS_FILE .gitlab/push-test-metrics.sh && false)
+ - hadrian/build.cabal.sh --flavour=$FLAVOUR -j`mk/detect-cpu-count.sh` --docs=no-sphinx test --summary-junit=./junit.xml --test-compiler=$TOP/_build/install/bin/ghc || (.gitlab/push-test-metrics.sh && false)
- |
# Push git notes.
- METRICS_FILE=$METRICS_FILE .gitlab/push-test-metrics.sh
+ .gitlab/push-test-metrics.sh
cache:
key: hadrian
paths:
diff --git a/hadrian/src/Settings/Builders/RunTest.hs b/hadrian/src/Settings/Builders/RunTest.hs
index 96df86606e..a26092ef49 100644
--- a/hadrian/src/Settings/Builders/RunTest.hs
+++ b/hadrian/src/Settings/Builders/RunTest.hs
@@ -141,8 +141,7 @@ runTestBuilderArgs = builder RunTest ? do
, arg "--config", arg $ "stats_files_dir=" ++ statsFilesDir
, arg $ "--threads=" ++ show threads
, emitWhenSet testEnv $ \env -> arg ("--test-env=" ++ show env)
- , emitWhenSet testMetricsFile $ \file -> mconcat
- [ arg "--metrics-file", arg (show file) ]
+ , emitWhenSet testMetricsFile $ \file -> arg ("--metrics-file=" ++ file)
, getTestArgs -- User-provided arguments from command line.
]