ci: Add 32-bit REPR_B build.

This showed up some interesting errors (hopefully all fixed now).

Signed-off-by: Jeff Epler <jepler@gmail.com>
This commit is contained in:
Jeff Epler 2025-07-15 18:51:25 +01:00
parent 2961a5fd3e
commit ec07a71df2
2 changed files with 31 additions and 0 deletions

View file

@ -102,6 +102,20 @@ jobs:
if: failure()
run: tests/run-tests.py --print-failures
coverage_repr_b:
runs-on: ubuntu-22.04 # use 22.04 to get libffi-dev:i386
steps:
- uses: actions/checkout@v4
- name: Install packages
run: source tools/ci.sh && ci_unix_32bit_setup
- name: Build
run: source tools/ci.sh && ci_unix_coverage_repr_b_build
- name: Run main test suite
run: source tools/ci.sh && ci_unix_coverage_repr_b_run_tests
- name: Print failures
if: failure()
run: tests/run-tests.py --print-failures
coverage_32bit:
runs-on: ubuntu-22.04 # use 22.04 to get libffi-dev:i386
steps:

View file

@ -522,6 +522,14 @@ CI_UNIX_OPTS_SANITIZE_UNDEFINED=(
LDFLAGS_EXTRA="-fsanitize=undefined -fno-sanitize=nonnull-attribute"
)
CI_UNIX_OPTS_REPR_B=(
VARIANT=coverage
CFLAGS_EXTRA="-DMICROPY_OBJ_REPR=MICROPY_OBJ_REPR_B -Dmp_int_t=int32_t -Dmp_uint_t=uint32_t"
MICROPY_FORCE_32BIT=1
RUN_TESTS_MPY_CROSS_FLAGS="--mpy-cross-flags=\"-march=x86 -msmall-int-bits=29\""
)
function ci_unix_build_helper {
make ${MAKEOPTS} -C mpy-cross
make ${MAKEOPTS} -C ports/unix "$@" submodules
@ -668,6 +676,15 @@ function ci_unix_32bit_setup {
python3 --version
}
function ci_unix_coverage_repr_b_build {
ci_unix_build_helper "${CI_UNIX_OPTS_REPR_B[@]}"
ci_unix_build_ffi_lib_helper gcc -m32
}
function ci_unix_coverage_repr_b_run_tests {
ci_unix_run_tests_helper "${CI_UNIX_OPTS_REPR_B[@]}"
}
function ci_unix_coverage_32bit_build {
ci_unix_build_helper VARIANT=coverage MICROPY_FORCE_32BIT=1
ci_unix_build_ffi_lib_helper gcc -m32