Skip to content

Commit 82472e4

Browse files
committed
Merge from 'main' to 'sycl-web' (311 commits)
CONFLICT (content): Merge conflict in llvm/include/llvm/IR/IntrinsicInst.h
2 parents e375133 + 0f4c9a0 commit 82472e4

File tree

2,105 files changed

+52842
-31163
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

2,105 files changed

+52842
-31163
lines changed

.ci/generate-buildkite-pipeline-premerge

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -238,9 +238,9 @@ if [[ "${linux_projects}" != "" ]]; then
238238
cat <<EOF
239239
- label: ':linux: Linux x64'
240240
artifact_paths:
241-
- artifacts/**/*
241+
- 'artifacts/**/*'
242242
- '*_result.json'
243-
- 'build/monolithic-linux/test-results.xml'
243+
- 'build/test-results.xml'
244244
agents: ${LINUX_AGENTS}
245245
retry:
246246
automatic:
@@ -261,9 +261,9 @@ if [[ "${windows_projects}" != "" ]]; then
261261
cat <<EOF
262262
- label: ':windows: Windows x64'
263263
artifact_paths:
264-
- artifacts/**/*
264+
- 'artifacts/**/*'
265265
- '*_result.json'
266-
- 'build/monolithic-windows/test-results.xml'
266+
- 'build/test-results.xml'
267267
agents: ${WINDOWS_AGENTS}
268268
retry:
269269
automatic:
@@ -290,7 +290,7 @@ if [[ -n "${ph_target_phid:-}" ]]; then
290290
- label: ':phabricator: update build status on Phabricator'
291291
agents: ${SERVICE_AGENTS}
292292
artifact_paths:
293-
- artifacts/**/*
293+
- 'artifacts/**/*'
294294
commands:
295295
- export SRC=\$\${BUILDKITE_BUILD_PATH}/llvm-premerge-checks
296296
- rm -rf \$\${SRC}

.ci/generate-buildkite-pipeline-scheduled

Lines changed: 29 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,18 @@
1414
# See https://buildkite.com/docs/agent/v3/cli-pipeline#pipeline-format.
1515
#
1616

17+
set -eu
18+
set -o pipefail
19+
20+
# Filter rules for generic windows tests
21+
: ${WINDOWS_AGENTS:='{"queue": "windows"}'}
22+
# Filter rules for generic linux tests
23+
: ${LINUX_AGENTS:='{"queue": "linux"}'}
24+
# Set by buildkite
25+
: ${BUILDKITE_MESSAGE:=}
26+
: ${BUILDKITE_COMMIT:=}
27+
: ${BUILDKITE_BRANCH:=}
28+
1729
cat <<EOF
1830
steps:
1931
- trigger: "libcxx-ci"
@@ -28,42 +40,42 @@ steps:
2840
commit: "${BUILDKITE_COMMIT}"
2941
branch: "${BUILDKITE_BRANCH}"
3042
31-
- label: ':linux: x64 Debian'
43+
- label: ':linux: Linux x64'
3244
artifact_paths:
33-
- '*_result.json'
34-
- 'build/monolithic-linux/test-results.xml'
35-
agents:
36-
queue: 'linux'
45+
- 'artifacts/**/*'
46+
- '*_result.json'
47+
- 'build/test-results.xml'
48+
agents: ${LINUX_AGENTS}
3749
retry:
3850
automatic:
3951
- exit_status: -1 # Agent was lost
4052
limit: 2
41-
- exit_status: 255
42-
limit: 2 # Forced agent shutdown
53+
- exit_status: 255 # Forced agent shutdown
54+
limit: 2
4355
timeout_in_minutes: 120
4456
env:
4557
CC: 'clang'
4658
CXX: 'clang++'
4759
commands:
48-
- './.ci/monolithic-linux.sh "bolt;clang-tools-extra;compiler-rt;flang;libc;libclc;lld;llvm;mlir;polly;pstl" "check-all"'
60+
- ./.ci/monolithic-linux.sh "bolt;clang;clang-tools-extra;compiler-rt;flang;libc;libclc;lld;llvm;mlir;polly;pstl" "check-all"
4961
50-
- label: ':windows: x64 Windows'
62+
- label: ':windows: Windows x64'
5163
artifact_paths:
52-
- '*_result.json'
53-
- 'build/monolithic-windows/test-results.xml'
54-
agents:
55-
queue: 'windows'
64+
- 'artifacts/**/*'
65+
- '*_result.json'
66+
- 'build/test-results.xml'
67+
agents: ${WINDOWS_AGENTS}
5668
retry:
5769
automatic:
5870
- exit_status: -1 # Agent was lost
5971
limit: 2
60-
- exit_status: 255
61-
limit: 2 # Forced agent shutdown
72+
- exit_status: 255 # Forced agent shutdown
73+
limit: 2
6274
timeout_in_minutes: 150
6375
env:
6476
CC: 'cl'
6577
CXX: 'cl'
6678
LD: 'link'
6779
commands:
68-
- 'C:\\BuildTools\\Common7\\Tools\\VsDevCmd.bat -arch=amd64 -host_arch=amd64'
69-
- 'bash .ci/monolithic-windows.sh "clang-tools-extra;flang;libclc;lld;llvm;mlir;polly;pstl" "check-all"'
80+
- C:\\BuildTools\\Common7\\Tools\\VsDevCmd.bat -arch=amd64 -host_arch=amd64
81+
- bash .ci/monolithic-windows.sh "clang;clang-tools-extra;flang;libclc;lld;llvm;mlir;polly;pstl" "check-all"

.ci/monolithic-linux.sh

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -17,14 +17,19 @@ set -ex
1717
set -o pipefail
1818

1919
MONOREPO_ROOT="${MONOREPO_ROOT:="$(git rev-parse --show-toplevel)"}"
20-
BUILD_DIR="${BUILD_DIR:=${MONOREPO_ROOT}/build/monolithic-linux}"
21-
20+
BUILD_DIR="${BUILD_DIR:=${MONOREPO_ROOT}/build}"
2221
rm -rf ${BUILD_DIR}
2322

2423
ccache --zero-stats
25-
ccache --show-config
24+
25+
if [[ -n "${CLEAR_CACHE:-}" ]]; then
26+
echo "clearing cache"
27+
ccache --clear
28+
fi
29+
2630
function show-stats {
27-
ccache --print-stats
31+
mkdir -p artifacts
32+
ccache --print-stats > artifacts/ccache_stats.txt
2833
}
2934
trap show-stats EXIT
3035

@@ -47,4 +52,5 @@ cmake -S ${MONOREPO_ROOT}/llvm -B ${BUILD_DIR} \
4752
-D LLVM_CCACHE_BUILD=ON
4853

4954
echo "--- ninja"
50-
ninja -C ${BUILD_DIR} ${targets}
55+
# Targets are not escaped as they are passed as separate arguments.
56+
ninja -C "${BUILD_DIR}" ${targets}

.ci/monolithic-windows.sh

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,13 +17,19 @@ set -ex
1717
set -o pipefail
1818

1919
MONOREPO_ROOT="${MONOREPO_ROOT:="$(git rev-parse --show-toplevel)"}"
20-
BUILD_DIR="${BUILD_DIR:=${MONOREPO_ROOT}/build/monolithic-windows}"
20+
BUILD_DIR="${BUILD_DIR:=${MONOREPO_ROOT}/build}"
2121

2222
rm -rf ${BUILD_DIR}
2323

24+
if [[ -n "${CLEAR_CACHE:-}" ]]; then
25+
echo "clearing sccache"
26+
rm -rf "$SCCACHE_DIR"
27+
fi
28+
2429
sccache --zero-stats
2530
function show-stats {
26-
sccache --show-stats
31+
mkdir -p artifacts
32+
sccache --show-stats >> artifacts/sccache_stats.txt
2733
}
2834
trap show-stats EXIT
2935

@@ -45,4 +51,5 @@ cmake -S ${MONOREPO_ROOT}/llvm -B ${BUILD_DIR} \
4551
-D CMAKE_CXX_COMPILER_LAUNCHER=sccache
4652

4753
echo "--- ninja"
48-
ninja -C ${BUILD_DIR} ${targets}
54+
# Targets are not escaped as they are passed as separate arguments.
55+
ninja -C "${BUILD_DIR}" ${targets}

.github/new-prs-labeler.yml

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -313,20 +313,13 @@ testing-tools:
313313
- llvm/utils/update*_test_checks.py
314314

315315
debuginfo:
316-
- llvm/include/llvm/DebugInfo/**
317-
- llvm/lib/DebugInfo/**
318-
- llvm/tools/dsymutil/**
319-
- llvm/tools/llvm-debuginfo-analyzer/**
320-
- llvm/tools/llvm-dwarfdump/**
321-
- llvm/tools/llvm-dwarfutil/**
322-
- llvm/tools/llvm-dwp/**
323-
- llvm/tools/llvm-gsymutil/**
324-
- llvm/tools/llvm-pdbutil/**
325-
- llvm/tools/llvm-debuginfod/**
326-
- llvm/tools/llvm-debuginfod-find/**
327-
- llvm/lib/CodeGen/AsmPrinter/**
328316
- clang/lib/CodeGen/CGDebugInfo.cpp
329317
- llvm/include/llvm/BinaryFormat/Dwarf.*
318+
- llvm/include/llvm/DebugInfo/**
319+
- llvm/include/llvm/IR/Debug*.h
320+
- llvm/lib/CodeGen/AsmPrinter/**
321+
- llvm/lib/DebugInfo/**
322+
- llvm/lib/IR/Debug*.cpp
330323
- llvm/test/DebugInfo/**
331324
- llvm/test/tools/dsymutil/**
332325
- llvm/test/tools/llvm-debuginfo-analyzer/**
@@ -337,8 +330,15 @@ debuginfo:
337330
- llvm/test/tools/llvm-dwp/**
338331
- llvm/test/tools/llvm-gsymutil/**
339332
- llvm/test/tools/llvm-pdbuti/**
340-
- llvm/lib/IR/Debug*.cpp
341-
- llvm/include/llvm/IR/Debug*.h
333+
- llvm/tools/dsymutil/**
334+
- llvm/tools/llvm-debuginfo-analyzer/**
335+
- llvm/tools/llvm-debuginfod/**
336+
- llvm/tools/llvm-debuginfod-find/**
337+
- llvm/tools/llvm-dwarfdump/**
338+
- llvm/tools/llvm-dwarfutil/**
339+
- llvm/tools/llvm-dwp/**
340+
- llvm/tools/llvm-gsymutil/**
341+
- llvm/tools/llvm-pdbutil/**
342342

343343
github:workflow:
344344
- .github/workflows/**

.github/workflows/clang-tests.yml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@ permissions:
66
on:
77
workflow_dispatch:
88
push:
9-
ignore-forks: true
109
branches:
1110
- 'release/**'
1211
paths:
@@ -15,7 +14,6 @@ on:
1514
- '.github/workflows/llvm-project-tests.yml'
1615
- '!llvm/**'
1716
pull_request:
18-
ignore-forks: true
1917
branches:
2018
- 'release/**'
2119
paths:

.github/workflows/issue-release-workflow.yml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ jobs:
3939
contains(github.event.action == 'opened' && github.event.issue.body || github.event.comment.body, '/cherry-pick')
4040
steps:
4141
- name: Fetch LLVM sources
42-
uses: actions/checkout@v3
42+
uses: actions/checkout@v4
4343
with:
4444
repository: llvm/llvm-project
4545
# GitHub stores the token used for checkout and uses it for pushes
@@ -55,9 +55,9 @@ jobs:
5555
5656
- name: Backport Commits
5757
run: |
58-
printf "$COMMENT_BODY" |
58+
printf "%s" "$COMMENT_BODY" |
5959
./llvm/utils/git/github-automation.py \
60-
--repo $GITHUB_REPOSITORY \
60+
--repo "$GITHUB_REPOSITORY" \
6161
--token ${{ secrets.RELEASE_WORKFLOW_PUSH_SECRET }} \
6262
release-workflow \
6363
--issue-number ${{ github.event.issue.number }} \
@@ -74,7 +74,7 @@ jobs:
7474
7575
steps:
7676
- name: Fetch LLVM sources
77-
uses: actions/checkout@v3
77+
uses: actions/checkout@v4
7878
with:
7979
persist-credentials: false
8080

@@ -84,9 +84,9 @@ jobs:
8484
8585
- name: Create Pull Request
8686
run: |
87-
printf "$COMMENT_BODY" |
87+
printf "%s" "$COMMENT_BODY" |
8888
./llvm/utils/git/github-automation.py \
89-
--repo $GITHUB_REPOSITORY \
89+
--repo "$GITHUB_REPOSITORY" \
9090
--token ${{ secrets.RELEASE_WORKFLOW_PUSH_SECRET }} \
9191
release-workflow \
9292
--issue-number ${{ github.event.issue.number }} \

.github/workflows/issue-subscriber.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,8 @@ jobs:
1515
steps:
1616
- name: Setup Automation Script
1717
run: |
18-
curl -O -L https://raw.githubusercontent.com/$GITHUB_REPOSITORY/$GITHUB_SHA/llvm/utils/git/github-automation.py
19-
curl -O -L https://raw.githubusercontent.com/$GITHUB_REPOSITORY/$GITHUB_SHA/llvm/utils/git/requirements.txt
18+
curl -O -L https://raw.githubusercontent.com/"$GITHUB_REPOSITORY"/"$GITHUB_SHA"/llvm/utils/git/github-automation.py
19+
curl -O -L https://raw.githubusercontent.com/"$GITHUB_REPOSITORY"/"$GITHUB_SHA"/llvm/utils/git/requirements.txt
2020
chmod a+x github-automation.py
2121
pip install -r requirements.txt
2222

.github/workflows/libclang-abi-tests.yml

Lines changed: 19 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -6,14 +6,12 @@ permissions:
66
on:
77
workflow_dispatch:
88
push:
9-
ignore-forks: true
109
branches:
1110
- 'release/**'
1211
paths:
1312
- 'clang/**'
1413
- '.github/workflows/libclang-abi-tests.yml'
1514
pull_request:
16-
ignore-forks: true
1715
branches:
1816
- 'release/**'
1917
paths:
@@ -41,7 +39,7 @@ jobs:
4139
LLVM_VERSION_PATCH: ${{ steps.version.outputs.LLVM_VERSION_PATCH }}
4240
steps:
4341
- name: Checkout source
44-
uses: actions/checkout@v3
42+
uses: actions/checkout@v4
4543
with:
4644
fetch-depth: 250
4745

@@ -52,32 +50,35 @@ jobs:
5250
- name: Setup Variables
5351
id: vars
5452
run: |
55-
minor_version=0
5653
remote_repo='https://github.com/llvm/llvm-project'
57-
if [ ${{ steps.version.outputs.LLVM_VERSION_MINOR }} -ne 0 -o ${{ steps.version.outputs.LLVM_VERSION_PATCH }} -eq 0 ]; then
54+
if [ ${{ steps.version.outputs.LLVM_VERSION_MINOR }} -ne 0 ] || [ ${{ steps.version.outputs.LLVM_VERSION_PATCH }} -eq 0 ]; then
5855
major_version=$(( ${{ steps.version.outputs.LLVM_VERSION_MAJOR }} - 1))
5956
baseline_ref="llvmorg-$major_version.0.0"
6057
6158
# If there is a minor release, we want to use that as the base line.
62-
minor_ref=$(git ls-remote --refs -t $remote_repo llvmorg-$major_version.[1-9].[0-9] | tail -n1 | grep -o 'llvmorg-.\+' || true)
59+
minor_ref=$(git ls-remote --refs -t "$remote_repo" llvmorg-"$major_version".[1-9].[0-9] | tail -n1 | grep -o 'llvmorg-.\+' || true)
6360
if [ -n "$minor_ref" ]; then
64-
baseline_ref=$minor_ref
61+
baseline_ref="$minor_ref"
6562
else
6663
# Check if we have a release candidate
67-
rc_ref=$(git ls-remote --refs -t $remote_repo llvmorg-$major_version.[1-9].[0-9]-rc* | tail -n1 | grep -o 'llvmorg-.\+' || true)
64+
rc_ref=$(git ls-remote --refs -t "$remote_repo" llvmorg-"$major_version".[1-9].[0-9]-rc* | tail -n1 | grep -o 'llvmorg-.\+' || true)
6865
if [ -n "$rc_ref" ]; then
69-
baseline_ref=$rc_ref
66+
baseline_ref="$rc_ref"
7067
fi
7168
fi
72-
echo "BASELINE_VERSION_MAJOR=$major_version" >> $GITHUB_OUTPUT
73-
echo "BASELINE_REF=$baseline_ref" >> $GITHUB_OUTPUT
74-
echo "ABI_HEADERS=clang-c" >> $GITHUB_OUTPUT
75-
echo "ABI_LIBS=libclang.so" >> $GITHUB_OUTPUT
69+
{
70+
echo "BASELINE_VERSION_MAJOR=$major_version"
71+
echo "BASELINE_REF=$baseline_ref"
72+
echo "ABI_HEADERS=clang-c"
73+
echo "ABI_LIBS=libclang.so"
74+
} >> "$GITHUB_OUTPUT"
7675
else
77-
echo "BASELINE_VERSION_MAJOR=${{ steps.version.outputs.LLVM_VERSION_MAJOR }}" >> $GITHUB_OUTPUT
78-
echo "BASELINE_REF=llvmorg-${{ steps.version.outputs.LLVM_VERSION_MAJOR }}.0.0" >> $GITHUB_OUTPUT
79-
echo "ABI_HEADERS=." >> $GITHUB_OUTPUT
80-
echo "ABI_LIBS=libclang.so libclang-cpp.so" >> $GITHUB_OUTPUT
76+
{
77+
echo "BASELINE_VERSION_MAJOR=${{ steps.version.outputs.LLVM_VERSION_MAJOR }}"
78+
echo "BASELINE_REF=llvmorg-${{ steps.version.outputs.LLVM_VERSION_MAJOR }}.0.0"
79+
echo "ABI_HEADERS=."
80+
echo "ABI_LIBS=libclang.so libclang-cpp.so"
81+
} >> "$GITHUB_OUTPUT"
8182
fi
8283
8384
abi-dump:
@@ -119,7 +120,7 @@ jobs:
119120
- name: Configure
120121
run: |
121122
mkdir install
122-
cmake -B build -S llvm -G Ninja -DLLVM_ENABLE_PROJECTS=clang -DCMAKE_BUILD_TYPE=Debug -DLLVM_TARGETS_TO_BUILD="" -DLLVM_BUILD_LLVM_DYLIB=ON -DLLVM_LINK_LLVM_DYLIB=ON -DCMAKE_C_FLAGS_DEBUG="-g1 -Og" -DCMAKE_CXX_FLAGS_DEBUG="-g1 -Og" -DCMAKE_INSTALL_PREFIX=$(pwd)/install llvm
123+
cmake -B build -S llvm -G Ninja -DLLVM_ENABLE_PROJECTS=clang -DCMAKE_BUILD_TYPE=Debug -DLLVM_TARGETS_TO_BUILD="" -DLLVM_BUILD_LLVM_DYLIB=ON -DLLVM_LINK_LLVM_DYLIB=ON -DCMAKE_C_FLAGS_DEBUG="-g1 -Og" -DCMAKE_CXX_FLAGS_DEBUG="-g1 -Og" -DCMAKE_INSTALL_PREFIX="$(pwd)"/install llvm
123124
- name: Build
124125
run: ninja -C build/ ${{ needs.abi-dump-setup.outputs.ABI_LIBS }} install-clang-headers
125126
- name: Dump ABI

.github/workflows/libclc-tests.yml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@ permissions:
66
on:
77
workflow_dispatch:
88
push:
9-
ignore-forks: true
109
branches:
1110
- 'release/**'
1211
paths:
@@ -16,7 +15,6 @@ on:
1615
- '!clang/**'
1716
- '!llvm/**'
1817
pull_request:
19-
ignore-forks: true
2018
branches:
2119
- 'release/**'
2220
paths:

.github/workflows/lld-tests.yml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@ permissions:
66
on:
77
workflow_dispatch:
88
push:
9-
ignore-forks: true
109
branches:
1110
- 'release/**'
1211
paths:
@@ -15,7 +14,6 @@ on:
1514
- '.github/workflows/llvm-project-tests.yml'
1615
- '!llvm/**'
1716
pull_request:
18-
ignore-forks: true
1917
branches:
2018
- 'release/**'
2119
paths:

0 commit comments

Comments
 (0)