Skip to content

Commit fd3b43e

Browse files
authored
Merge branch 'main' into perf/lv-delete-dead-loops
2 parents f32ca05 + febb4c4 commit fd3b43e

File tree

11,234 files changed

+966944
-440985
lines changed

Some content is hidden

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

11,234 files changed

+966944
-440985
lines changed

.ci/generate-buildkite-pipeline-premerge

Lines changed: 9 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99

1010
#
1111
# This file generates a Buildkite pipeline that triggers the various CI jobs for
12-
# the LLVM project during pre-commit CI (each time a Phabricator diff is uploaded).
12+
# the LLVM project during pre-commit CI.
1313
#
1414
# See https://buildkite.com/docs/agent/v3/cli-pipeline#pipeline-format.
1515
#
@@ -22,19 +22,18 @@ set -o pipefail
2222

2323
# Environment variables script works with:
2424

25-
# Fetch origin/main to have an up to date merge base for main...HEAD diff.
26-
git fetch origin main:main
25+
# Set by buildkite
26+
: ${BUILDKITE_PULL_REQUEST_BASE_BRANCH:=}
27+
: ${BUILDKITE_COMMIT:=}
28+
: ${BUILDKITE_BRANCH:=}
29+
# Fetch origin to have an up to date merge base for the diff.
30+
git fetch origin
2731
# List of files affected by this commit
28-
: ${MODIFIED_FILES:=$(git diff --name-only main...HEAD)}
32+
: ${MODIFIED_FILES:=$(git diff --name-only origin/${BUILDKITE_PULL_REQUEST_BASE_BRANCH}...HEAD)}
2933
# Filter rules for generic windows tests
3034
: ${WINDOWS_AGENTS:='{"queue": "windows"}'}
3135
# Filter rules for generic linux tests
3236
: ${LINUX_AGENTS:='{"queue": "linux"}'}
33-
# Service agents, for interacting with Phabricator.
34-
: ${SERVICE_AGENTS:='{"queue": "service"}'}
35-
# Set by buildkite
36-
: ${BUILDKITE_COMMIT:=}
37-
: ${BUILDKITE_BRANCH:=}
3837

3938
reviewID="$(git log --format=%B -n 1 | sed -nE 's/^Review-ID:[[:space:]]*(.+)$/\1/p')"
4039
if [[ "${reviewID}" != "" ]]; then
@@ -107,7 +106,7 @@ function add-dependencies() {
107106
done
108107
;;
109108
compiler-rt|libc|openmp)
110-
echo clang
109+
echo clang lld
111110
;;
112111
flang|lldb)
113112
for p in llvm clang; do
@@ -284,28 +283,3 @@ if [[ "${windows_projects}" != "" ]]; then
284283
- 'bash .ci/monolithic-windows.sh "$(echo ${windows_projects} | tr ' ' ';')" "$(echo ${windows_check_targets})"'
285284
EOF
286285
fi
287-
288-
# If build was triggered from a Phabricator review - send an update back.
289-
if [[ -n "${ph_target_phid:-}" ]]; then
290-
cat << EOF
291-
- continue_on_failure: true
292-
wait: '~'
293-
- label: ':phabricator: update build status on Phabricator'
294-
agents: ${SERVICE_AGENTS}
295-
artifact_paths:
296-
- 'artifacts/**/*'
297-
commands:
298-
- export SRC=\$\${BUILDKITE_BUILD_PATH}/llvm-premerge-checks
299-
- rm -rf \$\${SRC}
300-
- git clone --depth 1 https://github.com/google/llvm-premerge-checks.git "\$\${SRC}"
301-
- cd \$\${SRC}
302-
- git fetch origin "main":x
303-
- git checkout x
304-
- echo "llvm-premerge-checks commit"
305-
- git rev-parse HEAD
306-
- pip install -q -r \$\${SRC}/scripts/requirements.txt
307-
- cd "\$\$BUILDKITE_BUILD_CHECKOUT_PATH"
308-
- \$\${SRC}/scripts/summary.py
309-
timeout_in_minutes: 10
310-
EOF
311-
fi

.ci/generate-buildkite-pipeline-scheduled

Lines changed: 0 additions & 81 deletions
This file was deleted.

.ci/monolithic-linux.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ cmake -S ${MONOREPO_ROOT}/llvm -B ${BUILD_DIR} \
4545
-D LLVM_ENABLE_ASSERTIONS=ON \
4646
-D LLVM_BUILD_EXAMPLES=ON \
4747
-D COMPILER_RT_BUILD_LIBFUZZER=OFF \
48-
-D LLVM_LIT_ARGS="-v --xunit-xml-output ${BUILD_DIR}/test-results.xml" \
48+
-D LLVM_LIT_ARGS="-v --xunit-xml-output ${BUILD_DIR}/test-results.xml --timeout=1200 --time-tests" \
4949
-D LLVM_ENABLE_LLD=ON \
5050
-D CMAKE_CXX_FLAGS=-gmlt \
5151
-D BOLT_CLANG_EXE=/usr/bin/clang \

.ci/monolithic-windows.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ cmake -S ${MONOREPO_ROOT}/llvm -B ${BUILD_DIR} \
4545
-D LLVM_ENABLE_ASSERTIONS=ON \
4646
-D LLVM_BUILD_EXAMPLES=ON \
4747
-D COMPILER_RT_BUILD_LIBFUZZER=OFF \
48-
-D LLVM_LIT_ARGS="-v --xunit-xml-output ${BUILD_DIR}/test-results.xml" \
48+
-D LLVM_LIT_ARGS="-v --xunit-xml-output ${BUILD_DIR}/test-results.xml --timeout=1200 --time-tests" \
4949
-D COMPILER_RT_BUILD_ORC=OFF \
5050
-D CMAKE_C_COMPILER_LAUNCHER=sccache \
5151
-D CMAKE_CXX_COMPILER_LAUNCHER=sccache \

.github/CODEOWNERS

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -68,23 +68,26 @@
6868
/mlir/lib/Dialect/MemRef/Transforms/EmulateNarrowType.cpp @MaheshRavishankar @nicolasvasilache
6969

7070
# Vector Dialect in MLIR.
71-
/mlir/**/*AMX* @dcaballe
71+
/mlir/**/*AMX* @aartbik @dcaballe
7272
/mlir/**/*Neon* @banach-space @dcaballe @nicolasvasilache
7373
/mlir/**/*SME* @banach-space @dcaballe @nicolasvasilache
7474
/mlir/**/*SVE* @banach-space @dcaballe @nicolasvasilache
7575
/mlir/**/*VectorInterfaces* @dcaballe @nicolasvasilache
7676
/mlir/**/*VectorToSCF* @banach-space @dcaballe @nicolasvasilache @matthias-springer
7777
/mlir/**/*VectorToLLVM* @banach-space @dcaballe @nicolasvasilache
78-
/mlir/**/*X86Vector* @dcaballe @nicolasvasilache
78+
/mlir/**/*X86Vector* @aartbik @dcaballe @nicolasvasilache
7979
/mlir/include/mlir/Dialect/Vector @dcaballe @nicolasvasilache
8080
/mlir/lib/Dialect/Vector @dcaballe @nicolasvasilache
8181
/mlir/lib/Dialect/Vector/Transforms/VectorEmulateNarrowType.cpp @MaheshRavishankar @nicolasvasilache
8282
/mlir/**/*EmulateNarrowType* @hanhanW
8383
/mlir/lib/Dialect/Vector/Transforms/* @hanhanW @nicolasvasilache
8484

85+
# Presburger library in MLIR
86+
/mlir/**/*Presburger* @Groverkss @Superty
87+
8588
# Tensor Dialect in MLIR.
8689
/mlir/lib/Dialect/Tensor/IR/TensorTilingInterfaceImpl.cpp @hanhanW @nicolasvasilache
87-
/mlir/lib/Dialect/Tensor/Transforms/FoldIntoPackAndUnpackPatterns.cpp @hanhanW @nicolasvasilache
90+
/mlir/lib/Dialect/Tensor/Transforms/* @hanhanW @nicolasvasilache
8891

8992
# Transform Dialect in MLIR.
9093
/mlir/include/mlir/Dialect/Transform/* @ftynse @nicolasvasilache
@@ -95,3 +98,6 @@
9598
/mlir/**/SPIRVTo*/ @antiagainst @kuhar
9699
/mlir/**/*ToSPIRV/ @antiagainst @kuhar
97100
/mlir/tools/mlir-tblgen/SPIRVUtilsGen.cpp @antiagainst @kuhar
101+
102+
# MLIR Sparsifier.
103+
/mlir/**/*SparseTensor*/ @aartbik @PeimingLiu @yinying-lisa-li @matthias-springer

.github/dependabot.yml

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
version: 2
2+
updates:
3+
- package-ecosystem: "github-actions"
4+
directory: "/"
5+
schedule:
6+
interval: "monthly"
7+
groups:
8+
github-actions:
9+
patterns:
10+
- "*"
11+
- package-ecosystem: "pip"
12+
directory: "/llvm/docs"
13+
schedule:
14+
interval: "monthly"
15+
groups:
16+
llvm-docs-requirements:
17+
patterns:
18+
- "*"

.github/new-prs-labeler.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -308,6 +308,9 @@ clang-tidy:
308308
- clang-tools-extra/docs/clang-tidy/**
309309
- clang-tools-extra/test/clang-tidy/**
310310

311+
clang-tools-extra:
312+
- clang-tools-extra/**
313+
311314
tools:llvm-mca:
312315
- llvm/tools/llvm-mca/**
313316
- llvm/include/llvm/MCA/**
@@ -591,13 +594,16 @@ mlgo:
591594
- llvm/include/llvm/Analysis/*Runner.h
592595
- llvm/unittests/Analysis/ML*
593596
- llvm/lib/Analysis/FunctionPropertiesAnalysis.cpp
597+
- llvm/lib/Analysis/TrainingLogger.cpp
594598
- llvm/include/llvm/Analysis/FunctionPropertiesAnalysis.h
599+
- llvm/include/llvm/Analysis/Utils/TrainingLogger.h
595600
- llvm/test/Analysis/FunctionPropertiesAnalysis/*
596601
- llvm/unittests/Analysis/FunctionPropertiesAnalysisTest.cpp
597602
- llvm/test/Transforms/inline/ML/**
598603
- llvm/lib/CodeGen/ML*
599604
- llvm/unittests/CodeGen/ML*
600605
- llvm/test/CodeGen/MLRegAlloc/**
606+
- llvm/utils/mlgo-utils/*
601607

602608
tools:llvm-exegesis:
603609
- llvm/tools/llvm-exegesis/**

.github/workflows/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
Github action workflows should be stored in this directrory.
1+
Github action workflows should be stored in this directory.
Lines changed: 60 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,60 @@
1+
2+
name: Build CI Container
3+
4+
permissions:
5+
contents: read
6+
7+
on:
8+
push:
9+
branches:
10+
- main
11+
paths:
12+
- .github/workflows/build-ci-container.yml
13+
- '.github/workflows/containers/github-action-ci/**'
14+
pull_request:
15+
branches:
16+
- main
17+
paths:
18+
- .github/workflows/build-ci-container.yml
19+
- '.github/workflows/containers/github-action-ci/**'
20+
21+
jobs:
22+
build-ci-container:
23+
if: github.repository_owner == 'llvm'
24+
runs-on: ubuntu-latest
25+
permissions:
26+
packages: write
27+
steps:
28+
- name: Write Variables
29+
id: vars
30+
run: |
31+
tag=`date +%s`
32+
container_name="ghcr.io/$GITHUB_REPOSITORY_OWNER/ci-ubuntu-22.04"
33+
echo "container-name=$container_name" >> $GITHUB_OUTPUT
34+
echo "container-name-tag=$container_name:$tag" >> $GITHUB_OUTPUT
35+
36+
- name: Checkout LLVM
37+
uses: actions/checkout@v4
38+
with:
39+
sparse-checkout: .github/workflows/containers/github-action-ci/
40+
41+
- name: Build Container
42+
working-directory: ./.github/workflows/containers/github-action-ci/
43+
run: |
44+
podman build -t ${{ steps.vars.outputs.container-name-tag }} .
45+
podman tag ${{ steps.vars.outputs.container-name-tag }} ${{ steps.vars.outputs.container-name }}:latest
46+
47+
- name: Test Container
48+
run: |
49+
for image in ${{ steps.vars.outputs.container-name-tag }} ${{ steps.vars.outputs.container-name }}; do
50+
podman run --rm -it $image /usr/bin/bash -x -c 'printf '\''#include <iostream>\nint main(int argc, char **argv) { std::cout << "Hello\\n"; }'\'' | clang++ -x c++ - && ./a.out | grep Hello'
51+
done
52+
53+
- name: Push Container
54+
if: github.event_name == 'push'
55+
env:
56+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
57+
run: |
58+
podman login -u ${{ github.actor }} -p $GITHUB_TOKEN ghcr.io
59+
podman push ${{ steps.vars.outputs.container-name-tag }}
60+
podman push ${{ steps.vars.outputs.container-name }}:latest
Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
FROM docker.io/library/ubuntu:22.04 as base
2+
ENV LLVM_SYSROOT=/opt/llvm/
3+
4+
FROM base as toolchain
5+
ENV LLVM_MAJOR=17
6+
ENV LLVM_VERSION=${LLVM_MAJOR}.0.6
7+
ENV LLVM_DIRNAME=clang+llvm-${LLVM_VERSION}-x86_64-linux-gnu-ubuntu-22.04
8+
ENV LLVM_FILENAME=${LLVM_DIRNAME}.tar.xz
9+
10+
RUN apt-get update && \
11+
apt-get install -y \
12+
curl \
13+
xz-utils
14+
15+
RUN mkdir -p $LLVM_SYSROOT/bin/ $LLVM_SYSROOT/lib/
16+
17+
RUN curl -O -L https://github.com/llvm/llvm-project/releases/download/llvmorg-$LLVM_VERSION/$LLVM_FILENAME
18+
19+
RUN tar -C $LLVM_SYSROOT --strip-components=1 -xJf $LLVM_FILENAME \
20+
$LLVM_DIRNAME/bin/clang \
21+
$LLVM_DIRNAME/bin/clang++ \
22+
$LLVM_DIRNAME/bin/clang-cl \
23+
$LLVM_DIRNAME/bin/clang-$LLVM_MAJOR \
24+
$LLVM_DIRNAME/bin/lld \
25+
$LLVM_DIRNAME/bin/ld.lld \
26+
$LLVM_DIRNAME/lib/clang/
27+
28+
29+
FROM base
30+
31+
COPY --from=toolchain $LLVM_SYSROOT $LLVM_SYSROOT
32+
33+
# Need to install curl for hendrikmuhs/ccache-action
34+
# Need nodejs for some of the GitHub actions.
35+
# Need perl-modules for clang analyzer tests.
36+
RUN apt-get update && \
37+
apt-get install -y \
38+
binutils \
39+
cmake \
40+
curl \
41+
libstdc++-11-dev \
42+
ninja-build \
43+
nodejs \
44+
perl-modules \
45+
python3-psutil
46+
47+
ENV LLVM_SYSROOT=$LLVM_SYSROOT
48+
ENV PATH=${LLVM_SYSROOT}/bin:${PATH}

0 commit comments

Comments
 (0)