[llvm] Propagate the Buildkite pre-merge setup to GitHub Action (PR #81077)
Mehdi Amini via llvm-commits
llvm-commits at lists.llvm.org
Wed Feb 7 19:21:11 PST 2024
https://github.com/joker-eph updated https://github.com/llvm/llvm-project/pull/81077
>From f7a04b694ab54066d00d388d83cf039af041c8b7 Mon Sep 17 00:00:00 2001
From: Mehdi Amini <joker.eph at gmail.com>
Date: Wed, 7 Feb 2024 17:53:19 -0800
Subject: [PATCH] Propagate the Buildkite pre-merge setup to GitHub Action
This is a WIP, the Buildkite script is .ci/generate-buildkite-pipeline-premerge
---
.github/workflows/bolt-tests.yml | 37 ++++++++++++++++++++++++
.github/workflows/flang-tests.yml | 36 +++++++++++++++++++++++
.github/workflows/lld-tests.yml | 6 ++--
.github/workflows/llvm-project-tests.yml | 2 +-
.github/workflows/llvm-tests.yml | 4 ++-
.github/workflows/mlir-tests.yml | 36 +++++++++++++++++++++++
6 files changed, 117 insertions(+), 4 deletions(-)
create mode 100644 .github/workflows/bolt-tests.yml
create mode 100644 .github/workflows/flang-tests.yml
create mode 100644 .github/workflows/mlir-tests.yml
diff --git a/.github/workflows/bolt-tests.yml b/.github/workflows/bolt-tests.yml
new file mode 100644
index 00000000000000..c10947b507b571
--- /dev/null
+++ b/.github/workflows/bolt-tests.yml
@@ -0,0 +1,37 @@
+name: Bolt Tests
+
+permissions:
+ contents: read
+
+on:
+ workflow_dispatch:
+ push:
+ branches:
+ - 'main'
+ paths:
+ - 'bolt/**'
+ - '.github/workflows/bolt-tests.yml'
+ - '.github/workflows/llvm-project-tests.yml'
+ pull_request:
+ branches:
+ - 'main'
+ paths:
+ - 'bolt/**'
+ - '.github/workflows/bolt-tests.yml'
+ - '.github/workflows/llvm-project-tests.yml'
+
+concurrency:
+ # Skip intermediate builds: always.
+ # Cancel intermediate builds: only if it is a pull request build.
+ group: ${{ github.workflow }}-${{ github.ref }}
+ cancel-in-progress: ${{ startsWith(github.ref, 'refs/pull/') }}
+
+jobs:
+ check-all:
+ if: github.repository_owner == 'llvm'
+ name: Build and Test
+ uses: ./.github/workflows/llvm-project-tests.yml
+ with:
+ build_target: check-bolt
+ projects: bolt;lld;llvm
+ os_list: '["ubuntu-latest"]' # tests are not supported yet on Windows
\ No newline at end of file
diff --git a/.github/workflows/flang-tests.yml b/.github/workflows/flang-tests.yml
new file mode 100644
index 00000000000000..07f508fb674df3
--- /dev/null
+++ b/.github/workflows/flang-tests.yml
@@ -0,0 +1,36 @@
+name: Flang Tests
+
+permissions:
+ contents: read
+
+on:
+ workflow_dispatch:
+ push:
+ branches:
+ - 'main'
+ paths:
+ - 'flang/**'
+ - '.github/workflows/flang-tests.yml'
+ - '.github/workflows/llvm-project-tests.yml'
+ pull_request:
+ branches:
+ - 'main'
+ paths:
+ - 'flang/**'
+ - '.github/workflows/flang-tests.yml'
+ - '.github/workflows/llvm-project-tests.yml'
+
+concurrency:
+ # Skip intermediate builds: always.
+ # Cancel intermediate builds: only if it is a pull request build.
+ group: ${{ github.workflow }}-${{ github.ref }}
+ cancel-in-progress: ${{ startsWith(github.ref, 'refs/pull/') }}
+
+jobs:
+ check-all:
+ if: github.repository_owner == 'llvm'
+ name: Build and Test
+ uses: ./.github/workflows/llvm-project-tests.yml
+ with:
+ build_target: check-flang
+ projects: flang;clang
\ No newline at end of file
diff --git a/.github/workflows/lld-tests.yml b/.github/workflows/lld-tests.yml
index 599c0975fa6858..7a22990e2ab6c8 100644
--- a/.github/workflows/lld-tests.yml
+++ b/.github/workflows/lld-tests.yml
@@ -8,6 +8,7 @@ on:
push:
branches:
- 'release/**'
+ - 'main'
paths:
- 'lld/**'
- '.github/workflows/lld-tests.yml'
@@ -16,6 +17,7 @@ on:
pull_request:
branches:
- 'release/**'
+ - 'main'
paths:
- 'lld/**'
- '.github/workflows/lld-tests.yml'
@@ -34,5 +36,5 @@ jobs:
name: Test lld
uses: ./.github/workflows/llvm-project-tests.yml
with:
- build_target: check-lld
- projects: lld
+ build_target: check-lld check-bolt check-cross-project-tests
+ projects: lld;
diff --git a/.github/workflows/llvm-project-tests.yml b/.github/workflows/llvm-project-tests.yml
index 68b4a68d1af984..5c84ef3441321f 100644
--- a/.github/workflows/llvm-project-tests.yml
+++ b/.github/workflows/llvm-project-tests.yml
@@ -124,7 +124,7 @@ jobs:
-DCMAKE_C_COMPILER_LAUNCHER=sccache \
-DCMAKE_CXX_COMPILER_LAUNCHER=sccache \
${{ inputs.extra_cmake_args }}
- ninja -C "$builddir" '${{ inputs.build_target }}'
+ ninja -C "$builddir" ${{ inputs.build_target }}
- name: Build and Test libclc
if: "!startsWith(matrix.os, 'windows') && contains(inputs.projects, 'libclc')"
diff --git a/.github/workflows/llvm-tests.yml b/.github/workflows/llvm-tests.yml
index 127628d76f1913..7a13047882afde 100644
--- a/.github/workflows/llvm-tests.yml
+++ b/.github/workflows/llvm-tests.yml
@@ -8,6 +8,7 @@ on:
push:
branches:
- 'release/**'
+ - 'main'
paths:
- 'llvm/**'
- '.github/workflows/llvm-tests.yml'
@@ -15,6 +16,7 @@ on:
pull_request:
branches:
- 'release/**'
+ - 'main'
paths:
- 'llvm/**'
- '.github/workflows/llvm-tests.yml'
@@ -33,7 +35,7 @@ jobs:
uses: ./.github/workflows/llvm-project-tests.yml
with:
build_target: check-all
- projects: clang;lld;libclc;lldb
+ projects: clang-tools-extra;compiler-rt;flang;libc;lldb;openmp;cross-project-tests
abi-dump-setup:
if: github.repository_owner == 'llvm'
diff --git a/.github/workflows/mlir-tests.yml b/.github/workflows/mlir-tests.yml
new file mode 100644
index 00000000000000..83df617e0c3f9e
--- /dev/null
+++ b/.github/workflows/mlir-tests.yml
@@ -0,0 +1,36 @@
+name: MLIR Tests
+
+permissions:
+ contents: read
+
+on:
+ workflow_dispatch:
+ push:
+ branches:
+ - 'main'
+ paths:
+ - 'mlir/**'
+ - '.github/workflows/mlir-tests.yml'
+ - '.github/workflows/llvm-project-tests.yml'
+ pull_request:
+ branches:
+ - 'main'
+ paths:
+ - 'mlir/**'
+ - '.github/workflows/mlir-tests.yml'
+ - '.github/workflows/llvm-project-tests.yml'
+
+concurrency:
+ # Skip intermediate builds: always.
+ # Cancel intermediate builds: only if it is a pull request build.
+ group: ${{ github.workflow }}-${{ github.ref }}
+ cancel-in-progress: ${{ startsWith(github.ref, 'refs/pull/') }}
+
+jobs:
+ check-all:
+ if: github.repository_owner == 'llvm'
+ name: Build and Test
+ uses: ./.github/workflows/llvm-project-tests.yml
+ with:
+ build_target: check-mlir check-flang
+ projects: mlir;flang;clang
More information about the llvm-commits
mailing list