Commit Graph

39 Commits

Author SHA1 Message Date
Andrew Lenharth 5d8f91164b [NFC] update build env 2022-02-16 17:49:39 -06:00
Andrew Lenharth b978979aa3
[NFC] bump build prior to llvm bump (#2641) 2022-02-16 15:04:38 -06:00
Julian Oppermann caadc9aa24
[CI] Use lld, and bump circt-ci-build image for that. (#2552) 2022-02-01 19:40:15 +01:00
Julian Oppermann 65a685efdc
[CI] Prevent yapf from linting .py.in files. (#2466) 2022-01-16 09:41:53 +01:00
Hideto Ueno 846a38fb9f
LLVM Submodule Update (#2225)
Bump LLVM for the following improvements:

- https://reviews.llvm.org/D113511
- https://reviews.llvm.org/D113641

This required modifications to work around the following changes to
upstream:

- Replace Identifier with StringAttr (https://reviews.llvm.org/D113536)
- Use mlir::NamedAttribute (https://reviews.llvm.org/D113956)
- Use macher::m_Any (https://reviews.llvm.org/D113905)
- Update printer/parser of types/attributes
  (https://reviews.llvm.org/D113637) to use AsmPrinter/Parser instead of
  DialectAsmParser/Printer

Co-authored-by: Martin Erhart <maerhart@outlook.com>
2021-12-01 00:14:17 -05:00
Hideto Ueno b343e135ab
[CI] Fix diff command for clang-tidy (#2162) 2021-11-13 04:57:49 +09:00
Hideto Ueno d160095524
[CI] Run clang-format after clang-tidy (#2103)
Currently, clang-format is not applied to the modification of clang-tidy. So it is troublesome if clang-tidy breaks clang-format.
2021-11-09 04:36:22 +09:00
Hideto Ueno c9082491cf
[CI] Add a sanity check job (#2063)
This PR moves sanity checks(clang-format, python-format) to the beginning of CI as a new job.
2021-11-08 15:20:42 +09:00
Hideto Ueno 6608f5b9b3 [NFC][CI] Fix trailing white spaces 2021-11-05 11:52:10 +09:00
mikeurbach 443b2f412c
[Python] Add and document setup.py script for Python bindings. (#1913)
This allows users to `pip install lib/Bindings/Python`. Similarly,
this supports `pip wheel lib/Bindings/Python`. The script generally
follows https://github.com/llvm/torch-mlir/pull/256, with some tweaks
that are specific to CIRCT's CMake choices (e.g. using an external
projects unified build).
2021-10-01 14:20:00 -06:00
mikeurbach 33e975e855
[Python][CI] Fix formatting check by using an image with toml. (#1906)
This is required by the yapf tool we use to enforce formatting. Switch
back to using bash syntax for this check. Also re-format a few spots
that slipped in while the check was broken. Fixes #1162.
2021-09-30 09:40:37 -06:00
Andrew Young e16c134c03
[CI] Update pull request testing image (#1534)
The new image uses LLVM 12, notably pulling in a newer version of clang
and clang-format.
2021-08-26 11:04:20 -07:00
Andrew Young af021ef6a1
[CI] Fix shell usage (#1380)
When we switched to using docker for our PR builds, the default shell
changed from `bash` to `sh`.  This change makes the workflow file
`sh` compatible.
2021-07-07 15:45:51 -07:00
mikeurbach 945ad15862
[Python] Fix format check by specifying bash as shell. (#1193)
The default shell is `sh -e {0}`, which leads to the error:

[[: not found

This uses `bash` instead of `sh`.
2021-06-03 11:59:44 -06:00
John Demme 9d2b9ac3fd
[CI] Upgrade to Ubuntu 20.04 docker image (#1061)
Fixes the CI checks.
2021-05-16 19:18:21 -07:00
Ayush Anand 1ae59c60d5
Updated the workflow file and key (#943)
Co-authored-by: Ayush Anand <ayush100anand@gmailcom>
2021-04-22 21:26:34 -07:00
mikeurbach c064a6b32f
[NFC] Re-enable Python format check, and don't fail when no changes. (#948)
The intent of the check was to only run yapf on the files that
changed, but if no Python files changed, the grep command returns 1
and fails the check. In that case, return an empty list of files, and
check for that before running yapf.
2021-04-22 11:46:25 -06:00
Mike Urbach c83f888e26 [NFC] Disable new Python format check in CI.
This was failing unrelated PRs, disabling for now rather than reverting.
2021-04-22 10:58:27 -06:00
Mike Urbach b0e69ae120 [Python][CI] Add yapf formatting guidelines and run check in CI.
This follows the same setup as MLIR and NPCOMP, using yapf and the
Google style guidelines, with two-space indentation.
2021-04-21 15:38:02 -06:00
John Demme d4045dd9cb
[LLVM] Update LLVM submodule and the way it's cached (#891)
Bumping LLVM to get llvm/llvm-project@0126e90. Updating the workflow since there's no reason to cache the LLVM source code. Doing both simultaneously to save compilation resources.
2021-04-06 16:28:50 -07:00
mikeurbach 186f8faf8f
Lock GitHub workflows to ubuntu-18.04. (#771)
The `ubuntu-latest` tag is starting to point to Ubuntu 20.04, and this seemed to be causing issues related to finding `llvm-lit`. Stick to Ubuntu 18.04 explicitly for now.
2021-03-16 11:42:56 -06:00
Andrew Young 2d19c341fd [CI] Add GCC build, combine release and debug builds into release+assert
This change adds a GCC build to the buildAndTest job which is run on
every PR. This step takes about 1m 30s to complete.

This also combines the two clang builds, in release and debug mode, into
a single build, release+asserts. Normally, a cmake release build adds
-DNDEBUG to all command line options. The LLVM cmake system has a flag
to override this, LLVM_ENABLE_ASSERTIONS. Building in release mode with
assertions should give us the best of both worlds for error checking.

The GCC builds will be running in the same release+assert build
configuration.
2021-03-04 21:12:09 -08:00
Andrew Young e1a5000d1a [CI] Add BUILD_SHARED_LIBS to the pull request builds
BUILD_SHARED_LIBS builds all libraries as shared libraries.
Historically, this has mostly been used as a developer productivity
flag, as it greatly speeds up linking. The real value in testing with
this flag enabled is that it reveals mistakes in CMake library
dependencies, such as missing dependencies and circular dependencies.
Additionally, there has been recent effort to increase the level of
support for shared libraries to enable MLIR C/Python bindings, and
supporting this flag down the line is probably a must.
2021-02-24 02:36:30 -08:00
Andrew Young 08686ff731 Build circt-doc in CI
Some changes can break the `circt-doc` target without anyone noticing.
This change adds it to CI pre-merge checks.  Building the documentation
is very quick and should not affect build times in a significant way.
2021-02-04 21:49:39 -08:00
George Lyon 365f6ba576
[CMake] Configure unified build in CI (#411)
* Configure unified build in CI

* Fix unified build

Co-authored-by: George <989903+GeorgeLyon@users.noreply.github.com>
2021-01-06 13:21:07 -08:00
John Demme c803cff2f1 Build scheduling changes
Run builds on pushes/merges to 'main', on PRs, and upon request.
2020-12-29 19:54:42 -08:00
John Demme ac8ea5d10c
[LLVM] Creates llvm build script to avoid replication (#267)
Closes #265.
2020-11-20 13:10:49 -08:00
John Demme 4f44209b31
Fixing the workflow which GH broke (#250) 2020-11-16 21:22:33 -08:00
John Demme dc3b57de7e
Adding Verilator and a basic Verilator unit test (#179) 2020-10-30 13:12:15 -07:00
mikeurbach 80aaf3e37f
Fix shell script for displaying clang-format and clang-tidy patches (#170) 2020-10-20 19:45:11 -06:00
John Demme eb7a738d57
Fix the lint steps in the GH workflow to compare against the target branch (#137)
* Fix the lint steps to compare against the target branch

It was apparantly comparing against the fork point. Two different
meanings of the work base I think. As a result, it would pick up
differences in the target branch since the fork point! Users would have
to merge before the PR to avoid this.

* Documentation and breaking lines longer than 80 columns

(when possible)

* Missed a backslash
2020-10-13 10:51:08 -07:00
John Demme e3500b04ed
Fixing the push case (#132)
Quick fix

I'm assuming we're operating under the LLVM developer policies which allow no-review for obvious fixes...
2020-10-08 16:15:52 -07:00
John Demme 2db18341c5
Add git fetch step to fix clang-* diffs (#129)
Committing w/o review to fix workflow bug quickly. Does no harm if not correct.

* Add git fetch step to fix clang-* diffs

* Fixing -path directory on clang-tidy-diff call

clang-tidy-diff aparantly only looks for the build database if there are
revelant changes in the diff.

* Gotta add flag to export compile_commands.json
2020-10-08 15:48:31 -07:00
John Demme 8d3d08fdf7
Adds clang-tidy to the workflow (#128) 2020-10-08 13:52:58 -07:00
John Demme 2d82d657fe
Changing cache key to increase cache-hit rate slightly (#127) 2020-10-08 12:07:48 -07:00
John Demme 8ad98b1dfd
Adding clang-format check on push and PR (#110) 2020-10-08 11:07:48 -07:00
Sora Morimoto 438fdef6e3
Update actions/cache to v2 (#64)
Signed-off-by: Sora Morimoto <sora@morimoto.io>
2020-08-02 22:10:19 -07:00
stephenneuendorffer ad075335b8
Update LLVM version to c89e46e76 (#63)
* Update LLVM version to c89e46e76

A small fixup is required to avoid conflicts between ODS-generated build
methods because of default arguments.  Also, since this keeps failing, I've
updated the llvm cache so that it runs in a separate job.  Otherwise the cache is not updated when the CIRCT build fails.

* [LLHD] Add `SigType` conversion

* [LLHD] Add time type and constants conversion

Previously time constants were converted by their users, by creating a constant for each of the three time attributes. This makes time constants LLVM arrays containing the three time values instead, allowing more a more flexible use (e.g. passing time operands as block arguments).
* Add time type conversion.
* Add tme constants conversion.
* Add time operands to the process persistence state.
* Fix affected tests.

* [LLHD] Set LLVM::DialectCastOp as legal during `InstOp` lowering

This works around the PartialConversion failing because of the introduction of (unused) `DialectCastOps`, that will be dealt with later during the full conversion.

Co-authored-by: rodonisi <simon@rodoni.ch>
2020-07-31 11:32:38 -07:00
Tobias Grosser 8e45ce3728 Add CI using GitHub Action
This simple CI script builds CIRCT and runs 'make check-circt'.

The necessary LLVM submodule is automatically pulled and cached
to speed-up subsequent builds.
2020-06-29 05:16:07 +00:00