Commit Graph

260 Commits

Author SHA1 Message Date
Nikita Popov
f03a60d4d2 Use correct tokens in release issue workflow (#79300)
We should use the normal github.token for interacting with issues/PRs on
the repo, and separately pass the `--branch-repo-token` for creating the
branch in the llvmbot repo.
2024-01-24 16:05:56 +01:00
Nikita Popov
5db2e5801d Add necessary permissions to release issue workflow (#79272)
The `/cherry-pick` command needs `issues: write` to post a comment on
the issue. The `/branch` command also posts a comment, and also needs
`pull-requests: write` to open a PR.

This should fix the failure encountered at
https://github.com/llvm/llvm-project/issues/79253#issuecomment-1907850027.
2024-01-24 15:42:48 +01:00
Nikita Popov
416b079336 Fix release issue workflow (#79268)
Remove the `--phab-token` argument (which currently eats the subsequent
"auto" as the token no longer exists) and related code.

I think this will fix the workflow failure in
https://github.com/llvm/llvm-project/issues/79253#issuecomment-1907679229.
2024-01-24 11:23:28 +01:00
Aiden Grossman
c41472dbaf [Github] Only run libclang-python-tests on monorepo main
The libclang python binding test CI job currently doesn't have any
restrictions on what branches it will run on when something is pushed
and also isn't restricted to the monorepo. This patch adds a branch
restriction for the push event, only running the CI job when something
is pushed to the main branch (and the path filter is met), and also adds
a filter to ensure that the job comes from a PR against the monorepo or
a push to a branch in the monorepo.
2024-01-23 16:53:54 -08:00
Louis Dionne
eabddf22e2 [libc++] Run the nightly libc++ build at 03:00 Eastern for real (#79184)
The nightly libc++ build was incorrectly set up to build at 22:00
Eastern when it intended to run at 03:00 Eastern. This patch fixes that.
2024-01-23 15:27:54 -05:00
David Spickett
11c0dc3d40 [GitHub][workflows] Run automation script with python3 (#78695)
This means we don't have to chmod, or change permissions any other way.
2024-01-22 09:10:00 +00:00
Mark de Wever
1d6b6132ff [libc++] Reland CI module improvements.
Revert "Revert #76246 and #76083"

This reverts commit 5c150e7eeb.

Adds a small fix that should properly disable the tests on Windows.
Unfortunately the original poster has not provided feedback and the
original patch did not fail in the LLVM CI infrastructure.

Modules are known to fail on Windows due to non compliance of the
C library. Currently not having this patch prevents testing on other
platforms.
2024-01-21 12:10:36 +01:00
Aiden Grossman
61d098962e Revert "Add workflow to release mlgo utils"
This reverts commit aa04d2b78b.

Meant to push this to my fork and did not realize I was on main and not
a separate branch.
2024-01-21 06:43:01 +00:00
Aiden Grossman
aa04d2b78b Add workflow to release mlgo utils 2024-01-21 06:40:05 +00:00
Aiden Grossman
8e99a63899 [Github] Update paths for mlgo PR subscribers
This patch updates the paths in the PR labelling config for the MLGO
label. In particular, the path for the new mlgo-utils subfolder under
llvm/utils has been added and two other files that were missed in the
original introduction.
2024-01-21 03:37:18 +00:00
Daniil Dudkin
0175a1e4d3 new-prs-labeler: Add clang-tools-extra labeling (#78633)
There is no automatic labeling for the Extra Clang Tools, except
Clang-Tidy and ClangD.
2024-01-20 23:19:17 +03:00
Daniel Thornburgh
5c150e7eeb Revert #76246 and #76083
These cause test build failures on Windows.

This reverts the following commits:
  57ca748435
  d06ae33ec3
2024-01-18 15:07:33 -08:00
Tom Stellard
aa02002491 workflows: Refactor release-tasks.yml (#69523)
* Split out the lit release job and the documentation build job into
their own workflow files. This makes it possible to manually run these
jobs via workflow_dispatch.
    
* Improve tag/user validation and ensure it gets run for each release
task.
2024-01-17 17:17:00 -08:00
David Spickett
bbf2304d0a [GitHub][workflows] Replace curl with sparse checkout (#78303) 2024-01-17 10:31:44 +00:00
Craig Hesling
588802a670 [GitHub] Add python 3.7 to libclang python test (#77219)
This enables the libclang python binding test to check
the oldest version of Python supported in addition
to the normal python version.

It is important to check this for issue #76664, since
many new mainstream python type annotation features
and best practices are not compatible with older
versions of python.

Additionally, frustration around ever increasing
platform dependencies and versions has been raised.
This will help ensure that python maintains reasonable
backwards compatibility.

Adding this additional build step will increase the
run time, but this should always be minimal, since
the additional libclang compilation should see 100%
cache hit rate.

Issue #76664.
Fixes #76601.
2024-01-17 01:15:54 -08:00
Mark de Wever
d06ae33ec3 [libc++][modules] Removes module testing. (#76083)
This removes the entire modules testing infrastructure.

The current infrastructure uses CMake to generate the std and std.compat
module. This requires quite a bit of plumbing and uses CMake. Since
CMake introduced module support in CMake 3.26, modules have a higher
CMake requirement than the rest of the LLVM project. (The LLVM project
requires 3.20.) The main motivation for this approach was how libc++
generated its modules. Every header had its own module partition. This
was changed to improve performance and now only two modules remain. The
code to build these can be manually crafted.

A followup patch will reenable testing modules, using a different
approach.
2024-01-17 08:11:25 +01:00
Mark de Wever
7e909d58d1 [libc++][CI] Fixes documentation builder. (#78327)
The documentation CI no longer builds. This is likely introduced by
8f90e6937a. This fixes the issue.
2024-01-16 20:02:27 +01:00
Aart Bik
fc64a7342c [mlir][sparse][codeowners] add MLIR sparsifier team to codeowners (#78319) 2024-01-16 09:55:38 -08:00
Diogo Teles Sant'Anna
f3524e9aeb Hashpin sensitive dependencies and configure dependabot to update them automatically (#75859)
Closes #75620 

As I mentioned on the issue, this PR aims to hash-pin the CI
dependencies used on sensitive context -- i.e., they either are called
with write permissions, or are being used to build critical artifacts
like a release. In summary, this PR brings 3 changes:

1. Hash pin GitHub Actions called on sensitive context
2. Hash pin python dependencies used on sensitive context
3. Configure dependabot to automatically update those hashes
I'm further explaining the steps bellow.

The dependencies in format of GitHub Actions, I simply hash-pinned them.
I also made sure to keep the human-readable version as comments at the
same line.

At the
[release-tasks.yml](https://github.com/llvm/llvm-project/blob/main/.github/workflows/release-tasks.yml)
file, I've changed the installation method of some python dependencies
to install them considering their hashpinning. That required the
generation of a requirements file that had all the correct hashes, and
for that I used [pip-tools](https://pypi.org/project/pip-tools/2.0.0/).

While configuring dependabot, I set it to send a monthly PR updating all
the GitHub Actions, and a weekly PR to update any python dependency
required by
[/llvm/docs/requirements.txt](https://github.com/llvm/llvm-project/blob/main/llvm/docs/requirements.txt).

Let me know if you have any questions or concerns, I'd be happy to
clarify and help.

Thanks!

---------

Signed-off-by: Diogo Teles Sant'Anna <diogoteles@google.com>
2024-01-15 12:30:41 -08:00
Louis Dionne
8f90e6937a [runtimes] Use LLVM libunwind from libc++abi by default (#77687)
I recently came across LIBCXXABI_USE_LLVM_UNWINDER and was surprised to
notice it was disabled by default. Since we build libunwind by default
and ship it in the LLVM toolchain, it would seem to make sense that
libc++ and libc++abi rely on libunwind for unwinding instead of using
the system-provided unwinding library (if any).

Most importantly, using the system unwinder implies that libc++abi is
ABI compatible with that system unwinder, which is not necessarily the
case. Hence, it makes a lot more sense to instead default to using the
known-to-be-compatible LLVM unwinder, and let vendors manually select a
different unwinder if desired.

As a follow-up change, we should probably apply the same default to
compiler-rt.

Differential Revision: https://reviews.llvm.org/D150897
Fixes #77662
rdar://120801778
2024-01-11 10:13:21 -05:00
Louis Dionne
ca06c330fd [libc++] Allow running the test suite with optimizations (#68753)
This patch adds a configuration of the libc++ test suite that enables
optimizations when building the tests. It also adds a new CI
configuration to exercise this on a regular basis. This is added in the
context of [1], which requires building with optimizations in order to
hit the bug.

[1]: https://github.com/llvm/llvm-project/issues/68552
2024-01-09 10:39:14 -05:00
Craig Hesling
de15c55019 Revert "[GitHub] Fix slow sccache install on macOS by upgrading macOS version (#77165)" (#77270)
This reverts commit 602c8fa2d8, due to an
sccache issue seen on larger builds using macOS-12 runners.

The issue is documented in in the following issue:
https://github.com/hendrikmuhs/ccache-action/issues/174

The original PR is the following:
https://github.com/llvm/llvm-project/pull/77165
2024-01-08 09:54:12 -08:00
Craig Hesling
376baeb2d5 [GitHub] Add basic CI for libclang Python binding unit tests (#76784)
This is important to aid development of Python type annotations in the
libclang binding.
See https://github.com/llvm/llvm-project/issues/76664 for more details.

* Run on all pull requests and direct pushes.
* This makes use of the existing llvm-project-tests.yml recipe, which
will preload ccache from previous runs.
* Building libclang currently takes about 9mins when ccache is warm and
about an 1hr 20mins if it is cold using the standard GitHub ubuntu
runner.
* In the future, this could be broken into the following discrete steps
for clarity:
   1. Build libclang dependency.
       ninja -C build libclang
   2. Run Python unit tests.
       ninja -C build check-clang-python
* Followup changes will bring testing on older python versions and
static type checking.

Issue https://github.com/llvm/llvm-project/issues/76601.
2024-01-05 22:22:07 -08:00
Craig Hesling
cf02e6e710 [GitHub] Remove redundant cache key prefix (#76914)
Remove the redundant sccache cache key prefix.
This prefix is already added by the ccache action, which results in
cache keys like "sccache-sccache-ubuntu-...".

See the following source lines as proof:

2a51777f6f/src/restore.ts (L22-L23)
2024-01-05 22:15:10 -08:00
Craig Hesling
602c8fa2d8 [GitHub] Fix slow sccache install on macOS by upgrading macOS version (#77165)
The "Setup ccache" step on macOS-11 builds takes between 15 to 20 mins,
whereas this step takes a less than 10 seconds on other runners. The
bulk of this time is spent at the "Install sccache" step, where brew
emits warnings like "Warning: You are using macOS 11." and "We (and
Apple) do not provide support for this old version...".

Bumping the version of macOS greatly decreases this cache setup time to
about 20 seconds. Furthermore, it seems like it is speeding up general
build times, too.

It appears that
https://github.com/actions/virtual-environments/issues/5900 has been
resolved or obsoleted, so I do not believe
we need to lock macOS to 11 anymore.
2024-01-05 22:08:59 -08:00
Tom Stellard
3096353477 test-release.sh: Add a CMake cache file for 3-stage release builds (#75903)
You can now pass the -use-cmake-cache option to test-release.sh and it
will use a predefined cache file for building the release. This will
make it easier to reproduce the builds and add other enhancements like
PGO or bolt optimizations.

---------

Co-authored-by: Konrad Kleine <konrad.kleine@posteo.de>
2024-01-04 16:33:06 -08:00
Tom Stellard
166bd4e1f1 [workflows] Build a container for running CI on github actions (#75286)
Using a container will allow us to have similar testing environments on
both the GitHub hosted runners and the self-hosted runners.
2024-01-04 11:30:57 -08:00
Craig Hesling
ee94e548a1 [GitHub] Fix minor typos in .github/workflows (#76592)
Fix one spelling typo and remove second newline from end of files.
2024-01-03 10:35:39 -08:00
Han-Chung Wang
7a3b0cbb14 Update CODEOWNERS 2024-01-01 18:12:49 -08:00
Kunwar Grover
c7aa98558c [GitHub] Add default reviewers for Presburger library (#76627)
Added @Groverkss and @Superty as default reviewers for Presburger lib
paths.
2023-12-31 12:57:14 +05:30
eric
c03745d23a libc++-infa: Hotfix runner group
The runners-32 group is broken, for reasons...
The easiest fix is to move the jobs to runners-8.
(which needs to be renamed, because they're all actually 30 core
machines)
2023-12-21 21:34:21 -05:00
Matthias Springer
fd59f07f6a [mlir] Code owners: sort file and add myself (#76019) 2023-12-20 16:35:09 +09:00
Tom Stellard
c5b3b5e0e8 workflows/release-binaries: Add schedule to run job once per month (#73812)
This will help catch any regressions introduced in the main branch
before we start release testing.
2023-12-13 12:50:52 -08:00
Mark de Wever
ed210f9f5a [libc++][CI] Tests the no RTTI configuration. (#65518)
There are a few drive-by fixes:
- Since the combination RTTI disabled and exceptions enabled do not
work, this combination is prohibited.
- A small NFC in any fixing clang-tidy.

The code in the Buildkite configuration is prepared for using the std
module. There are more fixes needed for that configuration which will be
done in a separate commit.
2023-12-12 17:11:53 +01:00
David Spickett
c8655fce45 [GitHub] Remove author association print from new-prs workflow
Turns out, new contrbiutor association is in fact `NONE`.

Example: https://github.com/llvm/llvm-project/pull/75182

```
Run echo "$AUTHOR_ASSOCIATION"
NONE
```
2023-12-12 14:49:03 +00:00
David Spickett
7cee4704ae [GitHub] Try a workaround to get the new contributor greeting to work (#75036)
For reasons unknown, the FIRST_TIMER and FIRST_TIME_CONTRIBUTOR states
don't come through on new user PRs, I have opened
https://github.com/orgs/community/discussions/78038 to see if that's my
mistake or GitHub's.

In the meantime, a possible workaround is to check that we have none of
the other states. If there's some bug that means the first time
associations aren't available in workflows, maybe the association will
be "NONE".

Also added a debug step to print that association so I can add it to the
linked report. I will remove this as soon as I have 1 example PR.
2023-12-12 09:53:03 +00:00
Aiden Grossman
b3af755254 [Github] Set start rev to merge base in code format action (#75132)
This patch sets the start revision to the merge base so that the c++
formatting action won't produce any diffs related to changes in main but
not in the PR branch. This also leaves a TODO to migrate over to the
--diff_from_common_commit option in git-clang-format once LLVM v18 is
released.
2023-12-11 21:46:51 -08:00
Natalie Chouinard
f2afd10776 [github] Enable assertions on test workflow (#74849) 2023-12-11 13:58:18 -05:00
Nicolas Vasilache
0c9a20b0a1 Update CODEOWNERS 2023-12-08 16:40:57 +01:00
Diego Caballero
9349204a10 [GitHub] Add some default reviewers for mlir/Vector and mlir/Linalg (#74848) 2023-12-08 16:33:11 +01:00
Natalie Chouinard
155a013225 [SPIR-V] Add pre-commit CI workflow (#74092)
Add a pre-commit CI workflow for the experimental SPIR-V backend. This
action should only run when SPIR-V target or test files are modified.
The `codegen-spirv` tests don't run as part of `check-all` because the
SPIR-V backend is still experimental.

Depends on #73371 (for a green tree)
2023-12-07 09:42:30 -05:00
Eric
1e3af94253 Disable fail-fast for libc++ builders. (#74485)
It seems the fail fast just doesn't strike the right balance.
It wastes too many resources, especially if a build is killed because
the machine it was running on got preempted.

Instead, we should simply not run any future jobs if a failure has
occured, while letting the already running jobs finish.
2023-12-05 15:01:46 -05:00
David Spickett
77249546aa [GitHub] Add greeting comment to opened PRs from new contributors (#72384)
This includes some commonly needed information like how to add
reviewers.

This is implemented as a job before the labeler, so that on a new PR the
comment is added before there are any subscribers and only the author
gets a nofitication.

The labeler job depends on the greeter having run or having been
skipped. So if the PR wasn't just opened, or it's from a regular
contributor, the labeling still happens.

But we can be sure that when a greeting comment is left, it's the very
first thing we do.
2023-12-05 11:28:43 +00:00
Eric
4596dd103c Change how libc++ specifies the runners to use. (#74188)
Github actions has some quirks with how you use runner groups, labels,
names, etc... One of them is that groups can't "group" more than one set
of builders. To do that, you use the same name. So now we're specifying
the name.
2023-12-03 20:12:09 -05:00
Eric
0737be349d Add a scheduled build for libc++ (#73848)
We had a scheduled build on buildkite, we probably want something
testing head here as well.

Since this change just adds more tests, I think we can skip pre-commit  review.

[skip ci]
2023-11-29 17:36:44 -05:00
Eric
9ac64abc02 [libc++] Remove linux Buildkite builders entirely (#73825)
This removes the Google hosted Linux buildkite builders. We have since
moved all of them over to github actions.

Follow up changes will be sent for android.
2023-11-29 17:34:45 -05:00
Tom Stellard
f150ecc322 [workflows] Add top-level permissions for libcxx-build-and-test.yaml (#73689)
This is the standard convention for our workflow files.
2023-11-29 13:33:52 -08:00
Tom Stellard
dc16964f0e [workflows] Remove sync-release-repo.yml (#73682)
This should not be needed now that the project uses PRs, plus the
OpenSSF Scorecard report flagged this as insecure.
2023-11-29 07:53:51 -08:00
Chris Bieneman
488d900209 [NFC] Map changed file through envar
This sanitizes the string for printing.
2023-11-27 16:41:25 -06:00
Han-Chung Wang
6a9613eee7 [GitHub] Add @hanhanW to CODEOWNERS for relevant files. (#73571) 2023-11-27 13:53:23 -08:00