From 6d6e2c7358b2a4f8a39b87061170731951e6ef8b Mon Sep 17 00:00:00 2001 From: Ben Clayton Date: Fri, 19 Mar 2021 20:48:50 +0000 Subject: [PATCH] Kokoro: Switch from RelWithDebInfo to Release To try and speed up the presubmits a bit. Also add some stage duration timings, so we can tell what takes all the time. Bug: tint:652 Change-Id: Ic0a25a9485dc58e6d45b5129756fe9e704380d02 Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/45341 Reviewed-by: Antonio Maiorano Kokoro: Kokoro Commit-Queue: Ben Clayton --- kokoro/linux/cmake-clang-release-asan/build.sh | 2 +- kokoro/linux/cmake-clang-release/build.sh | 2 +- kokoro/linux/cmake-gcc-release/build.sh | 2 +- kokoro/linux/docker.sh | 13 +++++++++++++ 4 files changed, 16 insertions(+), 3 deletions(-) diff --git a/kokoro/linux/cmake-clang-release-asan/build.sh b/kokoro/linux/cmake-clang-release-asan/build.sh index 5799514d22..ed598aef01 100755 --- a/kokoro/linux/cmake-clang-release-asan/build.sh +++ b/kokoro/linux/cmake-clang-release-asan/build.sh @@ -20,7 +20,7 @@ SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}")" >/dev/null 2>&1 && pwd )" export BUILD_SYSTEM=cmake export BUILD_TOOLCHAIN=clang -export BUILD_TYPE=RelWithDebInfo +export BUILD_TYPE=Release export BUILD_SANITIZER=asan ${SCRIPT_DIR}/../build.sh diff --git a/kokoro/linux/cmake-clang-release/build.sh b/kokoro/linux/cmake-clang-release/build.sh index b889c81cbd..394f5bb427 100755 --- a/kokoro/linux/cmake-clang-release/build.sh +++ b/kokoro/linux/cmake-clang-release/build.sh @@ -20,6 +20,6 @@ SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}")" >/dev/null 2>&1 && pwd )" export BUILD_SYSTEM=cmake export BUILD_TOOLCHAIN=clang -export BUILD_TYPE=RelWithDebInfo +export BUILD_TYPE=Release ${SCRIPT_DIR}/../build.sh diff --git a/kokoro/linux/cmake-gcc-release/build.sh b/kokoro/linux/cmake-gcc-release/build.sh index 1bdee7ce8a..83af742eb4 100755 --- a/kokoro/linux/cmake-gcc-release/build.sh +++ b/kokoro/linux/cmake-gcc-release/build.sh @@ -20,6 +20,6 @@ SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}")" >/dev/null 2>&1 && pwd )" export BUILD_SYSTEM=cmake export BUILD_TOOLCHAIN=gcc -export BUILD_TYPE=RelWithDebInfo +export BUILD_TYPE=Release ${SCRIPT_DIR}/../build.sh diff --git a/kokoro/linux/docker.sh b/kokoro/linux/docker.sh index d02b6e3b91..8870b0c70d 100755 --- a/kokoro/linux/docker.sh +++ b/kokoro/linux/docker.sh @@ -18,12 +18,25 @@ set -e # Fail on any error. function show_cmds { set -x; } function hide_cmds { { set +x; } 2>/dev/null; } +function task_begin { + TASK_NAME="$@" + SECONDS=0 +} +function print_last_task_duration { + if [ ! -z "${TASK_NAME}" ]; then + echo "${TASK_NAME} completed in $(($SECONDS / 3600))h$((($SECONDS / 60) % 60))m$(($SECONDS % 60))s" + fi +} function status { + echo "" + echo "" + print_last_task_duration echo "" echo "*****************************************************************" echo "* $@" echo "*****************************************************************" echo "" + task_begin $@ } . /bin/using.sh # Declare the bash `using` function for configuring toolchains.