summaryrefslogtreecommitdiff
path: root/tests/inlineasm
AgeCommit message (Collapse)Author
2025-05-29py/emitinlinextensa: Add the rest of LX3 opcodes to the assembler.Alessandro Gatti
This commit expands the Xtensa inline assembler to support most if not all opcodes available on the ESP8266 and LX3 Xtensa cores. This is meant as a stepping stone to add inline assembler support for the ESP32 and its LX6 core, along to windowed-specific opcodes and additional opcodes that are present only on the LX7 core (ESP32-S3 and later). New opcodes being added are covered by tests, and the provided tests were expanded to also include opcodes available in the existing implementation. Given that the ESP8266 space requirements are tighter than ESP32's, certain opcodes that won't be commonly used have been put behind a define to save some space in the general use case. Signed-off-by: Alessandro Gatti <a.gatti@frob.it>
2025-01-02py/emitinlinerv32: Add inline assembler support for RV32.Alessandro Gatti
This commit adds support for writing inline assembler functions when targeting a RV32IMC processor. Given that this takes up a bit of rodata space due to its large instruction decoding table and its extensive error messages, it is enabled by default only on offline targets such as mpy-cross and the qemu port. Signed-off-by: Alessandro Gatti <a.gatti@frob.it>
2025-01-01tests/inlineasm: Make room for RV32IMC inline asm tests.Alessandro Gatti
Thumb/Thumb2 tests are now into their own subdirectory, as RV32IMC-specific tests will be added as part of the RV32 inline assembler support. Signed-off-by: Alessandro Gatti <a.gatti@frob.it>
2023-06-08tests: Replace umodule with module everywhere.Jim Mussared
This work was funded through GitHub Sponsors. Signed-off-by: Jim Mussared <jim.mussared@gmail.com>
2023-02-02top: Update Python formatting to black "2023 stable style".Jim Mussared
See https://black.readthedocs.io/en/stable/the_black_code_style/index.html Signed-off-by: Jim Mussared <jim.mussared@gmail.com>
2022-07-26py/compile: Support large integers in inline-asm data directive.Damien George
Fixes issue #8956. Signed-off-by: Damien George <damien@micropython.org>
2022-04-11tests/inlineasm: Add test for PUSH LR and POP PC.Christian Zietz
2020-03-30tests: Format all Python code with black, except tests in basics subdir.David Lechner
This adds the Python files in the tests/ directory to be formatted with ./tools/codeformat.py. The basics/ subdirectory is excluded for now so we aren't changing too much at once. In a few places `# fmt: off`/`# fmt: on` was used where the code had special formatting for readability or where the test was actually testing the specific formatting.
2019-10-22tests: Rename "array" module to "uarray".Damien George
2019-08-06py: Allow to pass in read-only buffers to viper and inline-asm funcs.Damien George
Fixes #4936.
2016-03-16tests: Add a test for argument passing to inline-asm functions.Damien George
2016-01-27py/inlineasm: Add ability to specify return type of asm_thumb funcs.Damien George
Supported return types are: object, bool, int, uint. For example: @micropython.asm_thumb def foo(r0, r1) -> uint: add(r0, r0, r1)
2016-01-07py/inlinethumb: Remove 30-bit restriction on movwt instruction.Damien George
movwt can now move a full 32-bit constant into a register.
2015-12-10py/emitinlinethumb: Add support for MRS instruction.Henrik Sölver
Only IPSR and BASEPRI special registers supported at the moment, but easy to extend in the future.
2015-10-31py: In inline asm, vldr and vstr offsets now in bytes not words.adminpete
As per ARM convention.
2015-10-19py: Add lsl/lsr/asr opcode support to inline Thumb2 assembler.Damien George
2015-04-19py/inlinethumb: Support for core floating point instructions.=
Adds support for the following Thumb2 VFP instructions, via the option MICROPY_EMIT_INLINE_THUMB_FLOAT: vcmp vsqrt vneg vcvt_f32_to_s32 vcvt_s32_to_f32 vmrs vmov vldr vstr vadd vsub vmul vdiv
2015-03-02tests: Add tests for inline assembler beq_n and beq_w ops.Damien George
2015-02-16py: Implement bl/bx instructions for inline Thumb assembler.Damien George
2015-02-13py: Implement clz and rbit for inline Thumb assembler.Damien George
2015-02-13py: Implement sdiv/udiv for inline Thumb assembler.Damien George
2015-02-13py: Implement push/pop for inline Thumb assembler.Damien George
2014-05-07tests: Add inline assembler test for pyboard.Damien George