diff options
| author | Alessandro Gatti <a.gatti@frob.it> | 2025-11-05 21:58:51 +0100 |
|---|---|---|
| committer | Damien George <damien@micropython.org> | 2025-11-27 14:18:04 +1100 |
| commit | 6b661ca3f6d877cfca224cc311cb84eba2d2b380 (patch) | |
| tree | 24eff371e22a03e2f0aff5cc59364bac7ae4b7ba | |
| parent | 65f994e26a852eecc2b641db4d35b5e1676d4442 (diff) | |
github/workflows: Test mpy-cross debug emitter.
This commit adds a new workflow step to the CI, to test the debug
emitter provided by mpy-cross. The checks being done are limited to
make sure that the debug emitter does not crash and emits opcodes for a
simple test file that is guaranteed to work for all configurations.
Signed-off-by: Alessandro Gatti <a.gatti@frob.it>
| -rw-r--r-- | .github/workflows/mpy_format.yml | 4 | ||||
| -rwxr-xr-x | tools/ci.sh | 9 |
2 files changed, 13 insertions, 0 deletions
diff --git a/.github/workflows/mpy_format.yml b/.github/workflows/mpy_format.yml index b51110db6..ab668c1cb 100644 --- a/.github/workflows/mpy_format.yml +++ b/.github/workflows/mpy_format.yml @@ -6,6 +6,8 @@ on: paths: - '.github/workflows/*.yml' - 'examples/**' + - 'mpy-cross/**' + - 'py/**' - 'tests/**' - 'tools/**' @@ -22,3 +24,5 @@ jobs: run: tools/ci.sh mpy_format_setup - name: Test mpy-tool.py run: tools/ci.sh mpy_format_test + - name: Test mpy-cross debug emitter + run: tools/ci.sh mpy_cross_debug_emitter diff --git a/tools/ci.sh b/tools/ci.sh index fa7a529b2..e34940f75 100755 --- a/tools/ci.sh +++ b/tools/ci.sh @@ -173,6 +173,15 @@ function ci_mpy_format_test { $micropython ./tools/mpy-tool.py -x -d examples/natmod/features1/features1.mpy } +function ci_mpy_cross_debug_emitter { + make ${MAKEOPTS} -C mpy-cross + mpy_cross=./mpy-cross/build/mpy-cross + + # Make sure the debug emitter does not crash or fail for simple files + $mpy_cross -X emit=native -march=debug ./tests/basics/0prelim.py | \ + grep -E "ENTRY|EXIT" | wc -l | grep "^2$" +} + ######################################################################################## # ports/cc3200 |
