From b5b4e59b473cddfd1d22fe0a16e2d3bf6f715164 Mon Sep 17 00:00:00 2001 From: Alex Crichton Date: Wed, 26 Jun 2019 01:34:17 -0700 Subject: [PATCH 1/6] ci: Turn of PR builds on Travis This commit turns off PR builds happening on Travis, instead entirely relying on Azure for PR builds to succeed. --- .travis.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.travis.yml b/.travis.yml index 3d185b4f0c9..464e95606e8 100644 --- a/.travis.yml +++ b/.travis.yml @@ -22,7 +22,7 @@ matrix: # Images used in testing PR and try-build should be run first. - env: IMAGE=x86_64-gnu-llvm-6.0 RUST_BACKTRACE=1 name: x86_64-gnu-llvm-6.0 - if: type = pull_request OR branch = auto + if: branch = auto - env: IMAGE=dist-x86_64-linux DEPLOY=1 name: dist-x86_64-linux @@ -227,7 +227,7 @@ matrix: if: branch = auto - env: IMAGE=mingw-check name: mingw-check - if: type = pull_request OR branch = auto + if: branch = auto - stage: publish toolstate if: branch = master AND type = push From 07efcf25c1a3de81da71d7ab9f40f013f4c78e0b Mon Sep 17 00:00:00 2001 From: Alex Crichton Date: Wed, 26 Jun 2019 01:38:08 -0700 Subject: [PATCH 2/6] ci: Disable assertions in PR builds The PR builder on Azure currently takes 2.5h which is a bit long, so this commit disables debug assertions and llvm assertions in an attempt to speed up that builder and have PR builds come back a bit more quickly. Other builders continue to enable debug assertions and test the compiler there. --- src/ci/docker/x86_64-gnu-llvm-6.0/Dockerfile | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/ci/docker/x86_64-gnu-llvm-6.0/Dockerfile b/src/ci/docker/x86_64-gnu-llvm-6.0/Dockerfile index 2932f373737..ef97f59cafd 100644 --- a/src/ci/docker/x86_64-gnu-llvm-6.0/Dockerfile +++ b/src/ci/docker/x86_64-gnu-llvm-6.0/Dockerfile @@ -25,3 +25,9 @@ ENV RUST_CONFIGURE_ARGS \ --llvm-root=/usr/lib/llvm-6.0 \ --enable-llvm-link-shared ENV SCRIPT python2.7 ../x.py test src/tools/tidy && python2.7 ../x.py test + +# The purpose of this container isn't to test with debug assertions and +# this is run on all PRs, so let's get speedier builds by disabling these extra +# checks. +ENV NO_DEBUG_ASSERTIONS=1 +ENV NO_LLVM_ASSERTIONS=1 From f6adc3945e5459459a615215baf9ec2145283d77 Mon Sep 17 00:00:00 2001 From: Alex Crichton Date: Wed, 26 Jun 2019 01:54:26 -0700 Subject: [PATCH 3/6] ci: Switch official `try` builds to happen on Azure This commit switches the `try` builers to officially happen on Azure Pipelines instead of Travis where they're currently run. This also cuts back the number of builders to just the two we run on Travis, leaving expansion as a possible future extension. --- .azure-pipelines/try.yml | 110 +++++++++++++++++++-------------------- .travis.yml | 4 +- 2 files changed, 57 insertions(+), 57 deletions(-) diff --git a/.azure-pipelines/try.yml b/.azure-pipelines/try.yml index e669925b5ff..6a22e57c124 100644 --- a/.azure-pipelines/try.yml +++ b/.azure-pipelines/try.yml @@ -1,13 +1,9 @@ -# -# Azure Pipelines "auto" branch build for Rust on Linux, macOS, and Windows. -# - pr: none trigger: - try variables: -- group: prod-credentials +- group: real-prod-credentials jobs: - job: Linux @@ -26,53 +22,57 @@ jobs: IMAGE: dist-x86_64-linux DEPLOY_ALT: 1 -- job: macOS - timeoutInMinutes: 600 - pool: - vmImage: macos-10.13 - steps: - - template: steps/run.yml - strategy: - matrix: - dist-x86_64-apple: - SCRIPT: ./x.py dist - RUST_CONFIGURE_ARGS: --target=aarch64-apple-ios,armv7-apple-ios,armv7s-apple-ios,i386-apple-ios,x86_64-apple-ios --enable-full-tools --enable-sanitizers --enable-profiler --enable-lldb --set rust.jemalloc - DEPLOY: 1 - RUSTC_RETRY_LINKER_ON_SEGFAULT: 1 - MACOSX_DEPLOYMENT_TARGET: 10.7 - NO_LLVM_ASSERTIONS: 1 - NO_DEBUG_ASSERTIONS: 1 - DIST_REQUIRE_ALL_TOOLS: 1 - - dist-x86_64-apple-alt: - SCRIPT: ./x.py dist - RUST_CONFIGURE_ARGS: --enable-extended --enable-profiler --enable-lldb --set rust.jemalloc - DEPLOY_ALT: 1 - RUSTC_RETRY_LINKER_ON_SEGFAULT: 1 - MACOSX_DEPLOYMENT_TARGET: 10.7 - NO_LLVM_ASSERTIONS: 1 - NO_DEBUG_ASSERTIONS: 1 - -- job: Windows - timeoutInMinutes: 600 - pool: - vmImage: 'vs2017-win2016' - steps: - - template: steps/run.yml - strategy: - matrix: - dist-x86_64-msvc: - RUST_CONFIGURE_ARGS: > - --build=x86_64-pc-windows-msvc - --target=x86_64-pc-windows-msvc,aarch64-pc-windows-msvc - --enable-full-tools - --enable-profiler - SCRIPT: python x.py dist - DIST_REQUIRE_ALL_TOOLS: 1 - DEPLOY: 1 - - dist-x86_64-msvc-alt: - MSYS_BITS: 64 - RUST_CONFIGURE_ARGS: --build=x86_64-pc-windows-msvc --enable-extended --enable-profiler - SCRIPT: python x.py dist - DEPLOY_ALT: 1 +# The macOS and Windows builds here are currently disabled due to them not being +# overly necessary on `try` builds. We also don't actually have anything that +# consumes the artifacts currently. Perhaps one day we can reenable, but for now +# it helps free up capacity on Azure. +# - job: macOS +# timeoutInMinutes: 600 +# pool: +# vmImage: macos-10.13 +# steps: +# - template: steps/run.yml +# strategy: +# matrix: +# dist-x86_64-apple: +# SCRIPT: ./x.py dist +# RUST_CONFIGURE_ARGS: --target=aarch64-apple-ios,armv7-apple-ios,armv7s-apple-ios,i386-apple-ios,x86_64-apple-ios --enable-full-tools --enable-sanitizers --enable-profiler --enable-lldb --set rust.jemalloc +# DEPLOY: 1 +# RUSTC_RETRY_LINKER_ON_SEGFAULT: 1 +# MACOSX_DEPLOYMENT_TARGET: 10.7 +# NO_LLVM_ASSERTIONS: 1 +# NO_DEBUG_ASSERTIONS: 1 +# DIST_REQUIRE_ALL_TOOLS: 1 +# +# dist-x86_64-apple-alt: +# SCRIPT: ./x.py dist +# RUST_CONFIGURE_ARGS: --enable-extended --enable-profiler --enable-lldb --set rust.jemalloc +# DEPLOY_ALT: 1 +# RUSTC_RETRY_LINKER_ON_SEGFAULT: 1 +# MACOSX_DEPLOYMENT_TARGET: 10.7 +# NO_LLVM_ASSERTIONS: 1 +# NO_DEBUG_ASSERTIONS: 1 +# +# - job: Windows +# timeoutInMinutes: 600 +# pool: +# vmImage: 'vs2017-win2016' +# steps: +# - template: steps/run.yml +# strategy: +# matrix: +# dist-x86_64-msvc: +# RUST_CONFIGURE_ARGS: > +# --build=x86_64-pc-windows-msvc +# --target=x86_64-pc-windows-msvc,aarch64-pc-windows-msvc +# --enable-full-tools +# --enable-profiler +# SCRIPT: python x.py dist +# DIST_REQUIRE_ALL_TOOLS: 1 +# DEPLOY: 1 +# +# dist-x86_64-msvc-alt: +# MSYS_BITS: 64 +# RUST_CONFIGURE_ARGS: --build=x86_64-pc-windows-msvc --enable-extended --enable-profiler +# SCRIPT: python x.py dist +# DEPLOY_ALT: 1 diff --git a/.travis.yml b/.travis.yml index 3d185b4f0c9..426019ecb48 100644 --- a/.travis.yml +++ b/.travis.yml @@ -26,14 +26,14 @@ matrix: - env: IMAGE=dist-x86_64-linux DEPLOY=1 name: dist-x86_64-linux - if: branch = try OR branch = auto + if: branch = auto # "alternate" deployments, these are "nightlies" but have LLVM assertions # turned on, they're deployed to a different location primarily for # additional testing. - env: IMAGE=dist-x86_64-linux DEPLOY_ALT=1 name: dist-x86_64-linux-alt - if: branch = try OR branch = auto + if: branch = auto - env: > SCRIPT="./x.py dist" From f78f37204e8b36e8166756fd89e0fe87e5cfe6d2 Mon Sep 17 00:00:00 2001 From: Alex Crichton Date: Wed, 26 Jun 2019 01:58:25 -0700 Subject: [PATCH 4/6] ci: Publish toolstate changes from Azure This commit moves toolstate publishing from Travis to Azure. We've been testing on azure for some time now and this works by deleting the Travis config and updating the credentials used on Azure. --- .azure-pipelines/master.yml | 2 +- .travis.yml | 10 ---------- 2 files changed, 1 insertion(+), 11 deletions(-) diff --git a/.azure-pipelines/master.yml b/.azure-pipelines/master.yml index e2baa923d99..9742c719658 100644 --- a/.azure-pipelines/master.yml +++ b/.azure-pipelines/master.yml @@ -7,7 +7,7 @@ trigger: - master variables: -- group: prod-credentials +- group: real-prod-credentials pool: vmImage: ubuntu-16.04 diff --git a/.travis.yml b/.travis.yml index 3d185b4f0c9..bc3cf920f4b 100644 --- a/.travis.yml +++ b/.travis.yml @@ -229,16 +229,6 @@ matrix: name: mingw-check if: type = pull_request OR branch = auto - - stage: publish toolstate - if: branch = master AND type = push - before_install: [] - install: [] - sudo: false - script: - MESSAGE_FILE=$(mktemp -t msg.XXXXXX); - . src/ci/docker/x86_64-gnu-tools/repo.sh; - commit_toolstate_change "$MESSAGE_FILE" "$TRAVIS_BUILD_DIR/src/tools/publish_toolstate.py" "$(git rev-parse HEAD)" "$(git log --format=%s -n1 HEAD)" "$MESSAGE_FILE" "$TOOLSTATE_REPO_ACCESS_TOKEN"; - before_install: # We'll use the AWS cli to download/upload cached docker layers as well as # push our deployments, so download that here. From db4f2367eefe4b43c2a56d342fb7c5e07a0082d3 Mon Sep 17 00:00:00 2001 From: Alex Crichton Date: Wed, 26 Jun 2019 02:18:55 -0700 Subject: [PATCH 5/6] ci: Sync AppVeyor/Travis with Azure configuration Manually make sure that we do the same thing across all the services, uncovering one spot where we needed to pass one more configure flag on Azure but otherwise we're good to go! --- .azure-pipelines/auto.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.azure-pipelines/auto.yml b/.azure-pipelines/auto.yml index 4f000e79bd0..3775fb14272 100644 --- a/.azure-pipelines/auto.yml +++ b/.azure-pipelines/auto.yml @@ -325,7 +325,7 @@ jobs: DEPLOY: 1 dist-i686-mingw: MSYS_BITS: 32 - RUST_CONFIGURE_ARGS: --build=i686-pc-windows-gnu --enable-full-tools + RUST_CONFIGURE_ARGS: --build=i686-pc-windows-gnu --enable-full-tools --enable-profiler SCRIPT: python x.py dist MINGW_URL: https://rust-lang-ci2.s3.amazonaws.com/rust-ci-mirror MINGW_ARCHIVE: i686-6.3.0-release-posix-dwarf-rt_v5-rev2.7z @@ -335,7 +335,7 @@ jobs: dist-x86_64-mingw: MSYS_BITS: 64 SCRIPT: python x.py dist - RUST_CONFIGURE_ARGS: --build=x86_64-pc-windows-gnu --enable-full-tools + RUST_CONFIGURE_ARGS: --build=x86_64-pc-windows-gnu --enable-full-tools --enable-profiler MINGW_URL: https://rust-lang-ci2.s3.amazonaws.com/rust-ci-mirror MINGW_ARCHIVE: x86_64-6.3.0-release-posix-seh-rt_v5-rev2.7z MINGW_DIR: mingw64 From 6772ebc27477827424fcf6297c7bfb03b52a88b3 Mon Sep 17 00:00:00 2001 From: Alex Crichton Date: Wed, 26 Jun 2019 11:13:08 -0700 Subject: [PATCH 6/6] ci: Disable x86_64-msvc-tools builder While we figure out what's wrong let's continue to land PRs --- .azure-pipelines/auto.yml | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/.azure-pipelines/auto.yml b/.azure-pipelines/auto.yml index 3775fb14272..c2ea8b756e0 100644 --- a/.azure-pipelines/auto.yml +++ b/.azure-pipelines/auto.yml @@ -251,10 +251,12 @@ jobs: RUST_CONFIGURE_ARGS: --build=x86_64-pc-windows-msvc VCVARS_BAT: vcvars64.bat # MSVC tools tests - x86_64-msvc-tools: - MSYS_BITS: 64 - SCRIPT: src/ci/docker/x86_64-gnu-tools/checktools.sh x.py /tmp/toolstates.json windows - RUST_CONFIGURE_ARGS: --build=x86_64-pc-windows-msvc --save-toolstates=/tmp/toolstates.json --enable-test-miri + # FIXME: broken on azure right now, need to figure out a cause and + # reenable + # x86_64-msvc-tools: + # MSYS_BITS: 64 + # SCRIPT: src/ci/docker/x86_64-gnu-tools/checktools.sh x.py /tmp/toolstates.json windows + # RUST_CONFIGURE_ARGS: --build=x86_64-pc-windows-msvc --save-toolstates=/tmp/toolstates.json --enable-test-miri # 32/64-bit MinGW builds. #