Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add RMC workflow file for GitHub Actions #31

Merged
merged 3 commits into from
Apr 14, 2021
Merged

Conversation

adpaco-aws
Copy link
Contributor

@adpaco-aws adpaco-aws commented Apr 13, 2021

Description of changes:

This PR adds

  • a workflow file rmc.yml in .github/workflows/
  • multiple setup scripts in scripts/setup/

to enable regression testing using GitHub Actions.

The workflow will run on push and pull_request changes using Ubuntu 20.04. We can extend this workflow to run on macOs or other systems in the future.

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

@adpaco-aws adpaco-aws force-pushed the rmc-ci branch 4 times, most recently from c164405 to 0646403 Compare April 13, 2021 15:45
@adpaco-aws adpaco-aws linked an issue Apr 13, 2021 that may be closed by this pull request
@adpaco-aws adpaco-aws force-pushed the rmc-ci branch 7 times, most recently from 360631d to 18e7517 Compare April 14, 2021 09:45
@adpaco-aws adpaco-aws added the [C] Internal Tracks some internal work. I.e.: Users should not be affected. label Apr 14, 2021
@@ -0,0 1,4 @@
# Install CBMC 5.27
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

needs a copyright notice.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we need it also in the other scripts and the workflow file?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes

@@ -0,0 1,4 @@
# Install CBMC 5.27
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These are ubuntu only. Either name them as such, or put them in an ubuntu folder

scripts/setup/install_rustup.sh Show resolved Hide resolved
scripts/setup/install_rustup.sh Show resolved Hide resolved
scripts/setup/install_llvm.sh Outdated Show resolved Hide resolved
@@ -0,0 1,22 @@
# Install tools via `apt-get`
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we have an ubuntu version requirement here? If so, make that explicit

Copy link
Contributor Author

@adpaco-aws adpaco-aws Apr 14, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, this is supposed to work for Ubuntu 20.04.

@@ -0,0 1,8 @@
# Use config.toml template and set debugging options
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why don't we just set these in the example config.toml

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some users may not want to do development work and just use the release version. In that case, we would have a different script for it.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe have a config.toml.development and config.toml.release?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Modify the README.md to point tho this?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes. Can we leave it for another PR? It's not necessary here, and have other changes in mind for it.

Comment on lines 1 to 2
# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
# SPDX-License-Identifier: Apache-2.0 OR MIT
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is the copyright needed in this file?

Copy link
Contributor

@danielsn danielsn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the set - flags should apply to all scripts.

@@ -0,0 1,12 @@
#!/bin/bash
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should this move under the ubuntu folder?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think so. It can be used in other systems, right?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

#!/bin/bash
################################################################################
# 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 script will install the llvm toolchain on the different
# Debian and Ubuntu versions

set -eux

Comment on lines 4 to 6
set -x
set -e
set -u
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actually, set -eux is cleaner

@@ -0,0 1,12 @@
#!/bin/bash
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

#!/bin/bash
################################################################################
# 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 script will install the llvm toolchain on the different
# Debian and Ubuntu versions

set -eux

@danielsn danielsn merged commit c3052b8 into main-2021-04-09 Apr 14, 2021
@danielsn danielsn deleted the rmc-ci branch April 14, 2021 19:33
adpaco-aws added a commit that referenced this pull request Apr 16, 2021
* Add RMC workflow file for GitHub Actions

* Add multiple setup scripts used by workflow

* Improvements for Actions worflow and setup scripts
adpaco-aws added a commit that referenced this pull request Apr 26, 2021
* Add RMC workflow file for GitHub Actions

* Add multiple setup scripts used by workflow

* Improvements for Actions worflow and setup scripts
adpaco-aws added a commit that referenced this pull request May 5, 2021
* Add RMC workflow file for GitHub Actions

* Add multiple setup scripts used by workflow

* Improvements for Actions worflow and setup scripts
adpaco-aws added a commit that referenced this pull request May 10, 2021
* Add RMC workflow file for GitHub Actions

* Add multiple setup scripts used by workflow

* Improvements for Actions worflow and setup scripts
adpaco-aws added a commit that referenced this pull request May 26, 2021
* Add RMC workflow file for GitHub Actions

* Add multiple setup scripts used by workflow

* Improvements for Actions worflow and setup scripts
adpaco-aws added a commit that referenced this pull request Jun 1, 2021
* Add RMC workflow file for GitHub Actions

* Add multiple setup scripts used by workflow

* Improvements for Actions worflow and setup scripts
adpaco-aws added a commit that referenced this pull request Jun 7, 2021
* Add RMC workflow file for GitHub Actions

* Add multiple setup scripts used by workflow

* Improvements for Actions worflow and setup scripts
adpaco-aws added a commit that referenced this pull request Jun 17, 2021
* Add RMC workflow file for GitHub Actions

* Add multiple setup scripts used by workflow

* Improvements for Actions worflow and setup scripts
adpaco-aws added a commit that referenced this pull request Jun 23, 2021
* Add RMC workflow file for GitHub Actions

* Add multiple setup scripts used by workflow

* Improvements for Actions worflow and setup scripts
adpaco-aws pushed a commit that referenced this pull request Jul 2, 2021
New lint: `disallowed_script_idents`

This PR implements a new lint to restrict locales that can be used in the code,
as proposed in #7376.

Current concerns / unresolved questions:

- ~~Mixed usage of `script` (as a Unicode term) and `locale` (as something that is easier to understand for the broad audience). I'm not sure whether these terms are fully interchangeable and whether in the current form it is more confusing than helpful.~~ `script` is now used everywhere.
- ~~Having to mostly copy-paste `AllowedScript`. Probably it's not a big problem, as the list of scripts is standardized and is unlikely to change, and even if we'd stick to the `unicode_script::Script`, we'll still have to implement custom deserialization, and I don't think that it will be shorter in terms of the amount of LoC.~~ `unicode::Script` is used together with a filtering deserialize function.
- Should we stick to the list of "recommended scripts" from [UAX #31](http://www.unicode.org/reports/tr31/#Table_Recommended_Scripts) in the configuration?

*Please write a short comment explaining your change (or "none" for internal only changes)*

changelog: ``[`disallowed_script_idents`]``

r? `@Manishearth`
adpaco-aws added a commit that referenced this pull request Jul 2, 2021
* Add RMC workflow file for GitHub Actions

* Add multiple setup scripts used by workflow

* Improvements for Actions worflow and setup scripts
adpaco-aws added a commit that referenced this pull request Jul 9, 2021
* Add RMC workflow file for GitHub Actions

* Add multiple setup scripts used by workflow

* Improvements for Actions worflow and setup scripts
adpaco-aws added a commit that referenced this pull request Jul 15, 2021
* Add RMC workflow file for GitHub Actions

* Add multiple setup scripts used by workflow

* Improvements for Actions worflow and setup scripts
adpaco-aws added a commit that referenced this pull request Jul 26, 2021
* Add RMC workflow file for GitHub Actions

* Add multiple setup scripts used by workflow

* Improvements for Actions worflow and setup scripts
adpaco-aws added a commit that referenced this pull request Aug 2, 2021
* Add RMC workflow file for GitHub Actions

* Add multiple setup scripts used by workflow

* Improvements for Actions worflow and setup scripts
@zhassan-aws zhassan-aws mentioned this pull request Aug 6, 2021
4 tasks
adpaco-aws added a commit that referenced this pull request Aug 6, 2021
* Add RMC workflow file for GitHub Actions

* Add multiple setup scripts used by workflow

* Improvements for Actions worflow and setup scripts
adpaco-aws added a commit that referenced this pull request Aug 17, 2021
* Add RMC workflow file for GitHub Actions

* Add multiple setup scripts used by workflow

* Improvements for Actions worflow and setup scripts
adpaco-aws added a commit that referenced this pull request Aug 24, 2021
* Add RMC workflow file for GitHub Actions

* Add multiple setup scripts used by workflow

* Improvements for Actions worflow and setup scripts
celinval referenced this pull request in celinval/kani-dev Nov 16, 2021
Use xor to implement Neg::neg for floats
tedinski pushed a commit to tedinski/rmc that referenced this pull request Apr 22, 2022
* Add RMC workflow file for GitHub Actions

* Add multiple setup scripts used by workflow

* Improvements for Actions worflow and setup scripts
tedinski pushed a commit to tedinski/rmc that referenced this pull request Apr 25, 2022
* Add RMC workflow file for GitHub Actions

* Add multiple setup scripts used by workflow

* Improvements for Actions worflow and setup scripts
tedinski pushed a commit to tedinski/rmc that referenced this pull request Apr 26, 2022
* Add RMC workflow file for GitHub Actions

* Add multiple setup scripts used by workflow

* Improvements for Actions worflow and setup scripts
tedinski pushed a commit that referenced this pull request Apr 27, 2022
* Add RMC workflow file for GitHub Actions

* Add multiple setup scripts used by workflow

* Improvements for Actions worflow and setup scripts
danielsn pushed a commit to danielsn/kani that referenced this pull request May 11, 2022
* Add RMC workflow file for GitHub Actions

* Add multiple setup scripts used by workflow

* Improvements for Actions worflow and setup scripts
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[C] Internal Tracks some internal work. I.e.: Users should not be affected.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

CI for regression testing
2 participants