aboutsummaryrefslogtreecommitdiff
path: root/libcxx/utils/ci/buildkite-pipeline.yml
blob: e42262620d5fb0137d5648aa8e21db3f923d1888 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
#===----------------------------------------------------------------------===##
#
# Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
# See https://llvm.org/LICENSE.txt for license information.
# SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
#
#===----------------------------------------------------------------------===##

#
# This file describes the various pre-commit CI bots used to test libc++.
#
# This file should never contain logic -- all the logic must be offloaded
# into scripts. This is critical to being able to reproduce CI issues outside
# of the CI environment, which is important for debugging.
#
# It is also worth noting that this script is split into several sections, the
# goal being to reduce the load on testers when a commit is known to fail.
#

# The Linux CI runners use the nightly ToT build provided by the Docker image.
# (Note the image isn't updated daily.) The LLVM_HEAD_VERSION contains that
# version number. The Linux CI runners for GCC use the latest stable version.
# Theses numbers are available in all runners, making it easier to update the
# version number.
env:
    # LLVM POST-BRANCH bump version
    # LLVM POST-BRANCH add compiler test for ToT - 1, e.g. "Clang 17"
    # LLVM RELEASE bump remove compiler ToT - 3, e.g. "Clang 15"
    LLVM_HEAD_VERSION: "18"   # Used compiler, update POST-BRANCH.
    GCC_STABLE_VERSION: "13"

definitions:
  _common: &common
    timeout_in_minutes: 120
    retry:
      automatic:
        - exit_status: -1  # Agent was lost
          limit: 2
    artifact_paths:
      - "**/test-results.xml"
      - "**/*.abilist"
      - "**/crash_diagnostics/*"

environment_definitions:
  _common_env: &common_env
      ENABLE_CLANG_TIDY: "On"
      LLVM_SYMBOLIZER_PATH: "/usr/bin/llvm-symbolizer-${LLVM_HEAD_VERSION}"
      CLANG_CRASH_DIAGNOSTICS_DIR: "crash_diagnostics"
      CC: clang-${LLVM_HEAD_VERSION}
      CXX: clang++-${LLVM_HEAD_VERSION}

  _absolute_path_clang: &absolute_path_clang
    # Note modules require and absolute path for clang-scan-deps
    # https://github.com/llvm/llvm-project/issues/61006
    CC: /usr/lib/llvm-${LLVM_HEAD_VERSION}/bin/clang
    CXX: /usr/lib/llvm-${LLVM_HEAD_VERSION}/bin/clang++


steps:
- group: ':mac: Apple'
  steps:
  - label: MacOS x86_64
    command: libcxx/utils/ci/run-buildbot generic-cxx23
    agents:
      queue: libcxx-builders
      os: macos
      arch: x86_64
    <<: *common

  - label: MacOS arm64
    command: libcxx/utils/ci/run-buildbot generic-cxx23
    agents:
      queue: libcxx-builders
      os: macos
      arch: arm64
    <<: *common

  - label: MacOS with Modules
    command: libcxx/utils/ci/run-buildbot generic-modules
    agents:
      queue: libcxx-builders
      os: macos
    <<: *common

  - label: MacOS with C++03
    command: libcxx/utils/ci/run-buildbot generic-cxx03
    agents:
      queue: libcxx-builders
      os: macos
    <<: *common

    # Build with the configuration we use to generate libc++.dylib on Apple platforms
  - label: Apple system
    command: libcxx/utils/ci/run-buildbot apple-system
    agents:
      queue: libcxx-builders
      os: macos
      arch: arm64 # This can technically run on any architecture, but we have more resources on arm64 so we pin this job to arm64
    <<: *common

  - label: Apple back-deployment macosx10.13
    command: libcxx/utils/ci/run-buildbot apple-system-backdeployment-10.13
    agents:
      queue: libcxx-builders
      os: macos
      arch: x86_64 # We need to use x86_64 for back-deployment CI on this target since macOS didn't support arm64 back then
    <<: *common

  - label: Apple back-deployment macosx10.15
    command: libcxx/utils/ci/run-buildbot apple-system-backdeployment-10.15
    agents:
      queue: libcxx-builders
      os: macos
      arch: x86_64 # We need to use x86_64 for back-deployment CI on this target since macOS didn't support arm64 back then
    <<: *common

  - label: Apple back-deployment with hardening enabled
    command: libcxx/utils/ci/run-buildbot apple-system-backdeployment-hardened-11.0
    agents:
      queue: libcxx-builders
      os: macos
      arch: x86_64 # TODO: Remove this once we are able to run back-deployment on arm64 again, since this isn't x86_64 specific
    <<: *common

- group: ARM
  steps:
  - label: AArch64
    command: libcxx/utils/ci/run-buildbot aarch64
    agents:
      queue: libcxx-builders-linaro-arm
      arch: aarch64
    <<: *common

  - label: AArch64 -fno-exceptions
    command: libcxx/utils/ci/run-buildbot aarch64-no-exceptions
    agents:
      queue: libcxx-builders-linaro-arm
      arch: aarch64
    <<: *common

  - label: Armv8
    command: libcxx/utils/ci/run-buildbot armv8
    agents:
      queue: libcxx-builders-linaro-arm
      arch: armv8l
    <<: *common

  - label: Armv8 -fno-exceptions
    command: libcxx/utils/ci/run-buildbot armv8-no-exceptions
    agents:
      queue: libcxx-builders-linaro-arm
      arch: armv8l
    <<: *common

  - label: Armv7
    command: libcxx/utils/ci/run-buildbot armv7
    agents:
      queue: libcxx-builders-linaro-arm
      arch: armv8l
    <<: *common

  - label: Armv7 -fno-exceptions
    command: libcxx/utils/ci/run-buildbot armv7-no-exceptions
    agents:
      queue: libcxx-builders-linaro-arm
      arch: armv8l
    <<: *common

  - label: Armv7-M picolibc
    command: libcxx/utils/ci/run-buildbot armv7m-picolibc
    agents:
      queue: libcxx-builders-linaro-arm
      arch: aarch64
    <<: *common

  - label: Armv7-M picolibc -fno-exceptions
    command: libcxx/utils/ci/run-buildbot armv7m-picolibc-no-exceptions
    agents:
      queue: libcxx-builders-linaro-arm
      arch: aarch64
    <<: *common

- group: AIX
  steps:
  - label: AIX (32-bit)
    command: libcxx/utils/ci/run-buildbot aix
    env:
      CC: clang
      CXX: clang++
      OBJECT_MODE: '32'
    agents:
      queue: libcxx-builders
      os: aix
    <<: *common

  - label: AIX (64-bit)
    command: libcxx/utils/ci/run-buildbot aix
    env:
      CC: clang
      CXX: clang++
      OBJECT_MODE: '64'
    agents:
      queue: libcxx-builders
      os: aix
    <<: *common

- group: ':freebsd: FreeBSD'
  steps:
  - label: FreeBSD 13 amd64
    command: libcxx/utils/ci/run-buildbot generic-cxx23
    env:
      CC: clang16
      CXX: clang++16
    agents:
      queue: libcxx-builders
      os: freebsd
    <<: *common

- group: ':android: Android'
  steps:
  - label: Android 5.0, x86 NDK
    command: libcxx/utils/ci/run-buildbot android-ndk-21-def-x86
    agents:
      queue: libcxx-builders
      os: android
    <<: *common

  - label: Android 13, x86_64 NDK
    command: libcxx/utils/ci/run-buildbot android-ndk-33-goog-x86_64
    agents:
      queue: libcxx-builders
      os: android
    <<: *common


    # TODO: Re-enable this once we've figured out how to run back-deployment testing on arm64 on recent OSes
    # - label: "Apple back-deployment macosx11.0 arm64"
    #   command: "libcxx/utils/ci/run-buildbot apple-system-backdeployment-11.0"
    #   artifact_paths:
    #     - "**/test-results.xml"
    #     - "**/*.abilist"
    #   agents:
    #     queue: "libcxx-builders"
    #     os: "macos"
    #     arch: "arm64"
    #   retry:
    #     automatic:
    #       - exit_status: -1  # Agent was lost
    #         limit: 2
    #   timeout_in_minutes: 120