jevsnes.git / third-party / rust / jgenesis / scripts / run-miri-tests.sh
1#!/usr/bin/env bash
2
3set -euo pipefail
4
5# Ensure miri runs with AVX2/AVX512 enabled if supported on this CPU
6export RUSTFLAGS="-C target-cpu=native"
7
8# Windowed sinc interpolator tests - reads from raw pointers using x86_64 intrinsics
9cargo +nightly miri test -p dsp
10
11# Boxed 2D array tests - allocates memory using unsafe code
12cargo +nightly miri test -p jgenesis-common
13
14# 32X bus tests - uses raw pointers to avoid lifetime params on the 32X SH-2 bus struct
15cargo +nightly miri test -p s32x-core
16cargo +nightly miri test -p genesis-core