@@ -30,8 +30,7 @@ pr_check_commits_task:
3030 fi
3131
3232x_check_task :
33- skip : $CIRRUS_PR == ""
34- name : (PR) Run ./x check
33+ name : Run ./x check
3534 # TODO(xdoardo): Figure out when it makes sense to have this dependency, or
3635 # how that dependency should actually work. Having this dependency would
3736 # pretty much mean making every PR that merges changes on `beta` to `master`
@@ -65,10 +64,9 @@ x_check_task:
6564 ui_test_script : CC="clang" CXX="clang++" ./x test ui
6665
6766build_core_task :
68- skip : $CIRRUS_PR == ""
69- name : (PR) Build `core` library for `riscv32cheriot-unknown-cheriotrtos`
67+ name : Build `core` library for `riscv32cheriot-unknown-cheriotrtos`
7068 depends_on :
71- - (PR) Run ./x check
69+ - Run ./x check
7270 timeout_in : 240m
7371 gce_instance : &arm_vm
7472 image_project : ubuntu-os-cloud
@@ -93,4 +91,41 @@ build_core_task:
9391 pull_master_script : git fetch origin master
9492 build_script : CC="clang" CXX="clang++" ./x build compiler std --target=riscv32cheriot-unknown-cheriotrtos
9593
94+ run_cheri_tests_task :
95+ name : Run CHERIoT-specific tests
96+ depends_on :
97+ - Build `core` library for `riscv32cheriot-unknown-cheriotrtos`
98+ timeout_in : 240m
99+ gce_instance : &arm_vm
100+ image_project : ubuntu-os-cloud
101+ image_family : ubuntu-2404-lts-arm64
102+ architecture : arm64
103+ zone : us-east1-b
104+ type : c4a-standard-16
105+ disk : 60
106+ spot : true
107+ env :
108+ CIRRUS_CLONE_DEPTH : 0
109+ CARGO_HOME : /tmp/cargo
110+ RUSTUP_HOME : /tmp/cargo
111+ XMAKE_ROOT : " y"
112+
113+ dependencies_script :
114+ - set -eo pipefail
115+ - apt-get update
116+ - apt-get install -y clang ninja-build lld cmake ccache perl opam z3 libgmp-dev
117+ install_xmake_script : curl -fsSL https://xmake.io/shget.text | bash || true # The installer will fail without any informations.
118+ verify_xmake_script : /root/.local/bin/xmake -v
119+ install_rust_script : curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | bash -s -- -y && . "$CARGO_HOME/env"
120+ verify_rust_script : . "$CARGO_HOME/env" && cargo --version
121+ build_sail_sim_script : git clone --recurse-submodules https://github.com/CHERIoT-Platform/cheriot-sail && cd cheriot-sail && opam init --reinit --bypass-check --disable-sandboxing --disable-shell-hook && eval $(opam env) && opam install sail --confirm-level=unsafe-yes && make csim && cp c_emulator/cheriot_sim /usr/local/bin
122+ gen_bootstrap_script : ./cheri/gen_bootstrap.sh --build-clang
123+ setup_env_script :
124+ - export CCACHE_REMOTE_STORAGE="http://${CIRRUS_HTTP_CACHE_HOST}/${CIRRUS_OS}/"
125+ - export CCACHE_REMOTE_ONLY=1
126+ - env
127+ pull_master_script : git fetch origin master
128+ build_rustc_script : CC="clang" CXX="clang++" ./x build compiler std --target=riscv32cheriot-unknown-cheriotrtos
129+ build_test_runner_script : cd ./cheri/tests/runner && . "$CARGO_HOME/env" && cargo build --release
130+ run_tests_script : cd ./cheri/tests && ./runner/target/release/cheriot-runner -vvvvv . --sysroot=../../build/host/llvm --rustc=../../build/host/stage1/bin/rustc --xmake=/root/.local/bin/xmake
96131# -- End PR tasks
0 commit comments