-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Selfhost: independent test runner (#477)
* Selfhost: independent test runner This adds a new test runner (in nodejs, for convenience) which uses the current installation of `abra` to run the lexer, parser, typechecker, and compiler tests against the assertion files. Once we start using features in the compiler that are _not_ supported by the reference implementation (for example, tuple destructuring, which is already an example of the selfhosted compiler advancing beyond the initial reference implementation), we will no longer rely on the original rust-based implementation. * Tar flags... * Tar flags... * github action debugging * github action debugging 2 * github action debugging 3 * github action debugging 4 * github action debugging 5 * github action debugging 6 * Cleanup, and adding colors to selfhost test runner * Selfhost: adding tuple destructuring Now that tuple destructuring is supported by the compiler (selfhosted) and we're bootstrapping using the initial selfhosted compiler, update the compiler to use tuple destructuring. Also, add a separate testing pass to build the next compiler and ensure the tests pass against that compiler too. * Removing old rust-based selfhosted test suite * Updating release gh actions script to not depend on reference rust+llvm compiler
- Loading branch information
Showing
18 changed files
with
1,307 additions
and
1,761 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
name: Test selfhosted | ||
|
||
on: | ||
push: | ||
branches: | ||
- master | ||
pull_request: | ||
|
||
env: | ||
CARGO_TERM_COLOR: always | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-22.04 | ||
steps: | ||
- name: Checkout source | ||
uses: actions/checkout@v2 | ||
- name: Cache QBE | ||
id: cache-qbe | ||
uses: actions/cache@v3 | ||
with: | ||
path: ./qbe/qbe-1.2 | ||
key: qbe-1.2 | ||
- name: Install QBE | ||
run: | | ||
mkdir -p qbe | ||
cd qbe | ||
wget https://c9x.me/compile/release/qbe-1.2.tar.xz | ||
tar -xf qbe-1.2.tar.xz | ||
cd qbe-1.2 | ||
make | ||
if: steps.cache-qbe.outputs.cache-hit != 'true' | ||
- name: Setup QBE | ||
run: | | ||
echo "PATH=$(pwd)/qbe/qbe-1.2:$PATH" >> $GITHUB_ENV | ||
- name: Install ext dependencies | ||
run: ./configure-libgc.sh | ||
- name: Install abra | ||
run: | | ||
mkdir abra-linux | ||
wget https://github.com/kengorab/abra-lang/releases/latest/download/abra-linux.tar.gz | ||
tar -xzf abra-linux.tar.gz -C abra-linux | ||
echo "PATH=$(pwd)/abra-linux:$PATH" >> $GITHUB_ENV | ||
echo "ABRA_HOME=`realpath $(pwd)/abra-linux/std`" >> $GITHUB_ENV | ||
- name: Run tests | ||
run: | | ||
cd selfhost | ||
node test/run-tests.js | ||
- name: Run tests against compiler-next | ||
run: | | ||
cd selfhost | ||
abra build -o compiler_next ./src/compiler.test.abra | ||
COMPILER_BIN=./._abra/compiler_next node test/run-tests.js |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,5 +6,4 @@ members = [ | |
"abra_lsp", | ||
"abra_native", | ||
"abra_wasm", | ||
"selfhost_test", | ||
] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.