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

Shard testsuite and parallelize #138

Open
titzer opened this issue Mar 1, 2023 · 0 comments
Open

Shard testsuite and parallelize #138

titzer opened this issue Mar 1, 2023 · 0 comments

Comments

@titzer
Copy link
Owner

titzer commented Mar 1, 2023

The test suite (aeneas test or test/all.bash) is mostly serial. That makes little use of the many cores available today. It could be made faster by introducing parallelism at several different granularities.

  1. Each test suite, e.g. test/core is run in serial with other test suites.
  2. Within a test suite, each step, e.g. "compile tests to target X", is serial.
  3. Within each step, all files in a suite are processed sequentially.

Each of these steps could benefit from parallelism, potentially. The only conceptual blocker has been organizing the test output of multiple running suites and making sure the runner is robust to crashes and hangs by any of the test steps.

For (3) I recently added batching because some suites like test/gc need to compile hundreds of tests, but each of them needs the runtime. Compiling them all in one v3c invocation typically runs out of memory, and running each individually is too slow when running on the JVM due to its abysmal startup. So the solution was to batch them into groups of 100 or so. Batching them also introduces the possibility to run batches in parallel.

I'd welcome any help in parallelizing the suite. I'd prefer to keep it shell scripts (rather than moving to Python), and adding utilities in C or Virgil (e.g. to manage many forked processes).

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

No branches or pull requests

1 participant