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

Clean up benchmark directories after building #2583

Merged
merged 5 commits into from
Jul 10, 2023

Conversation

karkhaz
Copy link
Contributor

@karkhaz karkhaz commented Jul 5, 2023

Description of changes:

This commit makes benchcomp delete fresh copies of benchmark directories after running the benchmark suite, by default. This is to save disk space, especially on CI machines which do not have enough disk space to run the perf suite. The new behavior can be turned off with the new --no-cleanup-run-dirs flag.

Resolved issues:

N/A

Related RFC:

N/A

Call-outs:

Here is a run where the benchcomp job succeeds after deleting the stale benchmark repos.

Testing:

  • How is this change tested?

Ran in CI

  • Is this a refactor change?

no

Checklist

  • Each commit message has a non-empty body, explaining why the change was made
  • Methods or procedures are documented
  • Regression or unit tests are included, or existing tests cover the modified code
  • My PR is restricted to a single feature or bugfix

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 and MIT licenses.

This commit makes benchcomp delete fresh copies of benchmark directories
after running the benchmark suite, by default. This is to save disk
space, especially on CI machines which do not have enough disk space to
run the perf suite. The new behavior can be turned off with the new
--no-cleanup-run-dirs flag.
@karkhaz karkhaz requested a review from a team as a code owner July 5, 2023 13:43
Copy link
Contributor

@celinval celinval left a comment

Choose a reason for hiding this comment

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

Sorry, it's not clear to me what this is actually cleaning and when. Can you please clarify?

In order to test this, I think we need to compare two versions of Kani that use a different toolchain. I think that is the main problem, probably because each toolchain takes around 2GB of disk.

tools/benchcomp/benchcomp/cmd_args.py Outdated Show resolved Hide resolved
@karkhaz
Copy link
Contributor Author

karkhaz commented Jul 5, 2023

Sorry, it's not clear to me what this is actually cleaning and when. Can you please clarify?

If you have a benchmark directory foo and configure benchcomp to run it twice with two different toolchains, benchcomp does not actually run the command inside foo. Instead it copies foo to a temporary location for each toolchain, and runs the command inside there. Previously benchcomp was not deleting these copies.

So for the kani-perf suite, in the CI machine, kani gets cloned, and then benchcomp makes two more copies of it to run with the old and new toolchain... and each of those copies of kani contain the whole git history and object files etc.

(I had previously considered making benchcomp ignore .git, but it turns out that for some repositories, the benchmark suite uses git for various reasons like finding the root of the repository etc).

@karkhaz karkhaz enabled auto-merge (squash) July 10, 2023 17:01
@karkhaz karkhaz merged commit bb53ec2 into model-checking:main Jul 10, 2023
@karkhaz karkhaz mentioned this pull request Jul 12, 2023
4 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants