8000 mpy-cross: Support armv7em, armv7emsp, armv7emdp architectures. · rlangoy/micropython@82a19cb · GitHub
[go: up one dir, main page]

Skip to content

Commit 82a19cb

Browse files
committed
mpy-cross: Support armv7em, armv7emsp, armv7emdp architectures.
1 parent 8ce6928 commit 82a19cb

File tree

1 file changed

+10
-1
lines changed

1 file changed

+10
-1
lines changed

mpy-cross/main.c

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@ STATIC int usage(char **argv) {
109109
"-msmall-int-bits=number : set the maximum bits used to encode a small-int\n"
110110
"-mno-unicode : don't support unicode in compiled strings\n"
111111
"-mcache-lookup-bc : cache map lookups in the bytecode\n"
112-
"-march=<arch> : set architecture for native emitter; x86, x64, armv6, armv7m, xtensa, xtensawin\n"
112+
"-march=<arch> : set architecture for native emitter; x86, x64, armv6, armv7m, armv7em, armv7emsp, armv7emdp, xtensa, xtensawin\n"
113113
"\n"
114114
"Implementation specific options:\n", argv[0]
115115
);
@@ -285,6 +285,15 @@ MP_NOINLINE int main_(int argc, char **argv) {
285285
} else if (strcmp(arch, "armv7m") == 0) {
286286
mp_dynamic_compiler.native_arch = MP_NATIVE_ARCH_ARMV7M;
287287
mp_dynamic_compiler.nlr_buf_num_regs = MICROPY_NLR_NUM_REGS_ARM_THUMB_FP;
288+
} else if (strcmp(arch, "armv7em") == 0) {
289+
mp_dynamic_compiler.native_arch = MP_NATIVE_ARCH_ARMV7EM;
290+
mp_dynamic_compiler.nlr_buf_num_regs = MICROPY_NLR_NUM_REGS_ARM_THUMB_FP;
291+
} else if (strcmp(arch, "armv7emsp") == 0) {
292+
mp_dynamic_compiler.native_arch = MP_NATIVE_ARCH_ARMV7EMSP;
293+
mp_dynamic_compiler.nlr_buf_num_regs = MICROPY_NLR_NUM_REGS_ARM_THUMB_FP;
294+
} else if (strcmp(arch, "armv7emdp") == 0) {
295+
mp_dynamic_compiler.native_arch = MP_NATIVE_ARCH_ARMV7EMDP;
296+
mp_dynamic_compiler.nlr_buf_num_regs = MICROPY_NLR_NUM_REGS_ARM_THUMB_FP;
288297
} else if (strcmp(arch, "xtensa") == 0) {
289298
mp_dynamic_compiler.native_arch = MP_NATIVE_ARCH_XTENSA;
290299
mp_dynamic_compiler.nlr_buf_num_regs = MICROPY_NLR_NUM_REGS_XTENSA;

0 commit comments

Comments
 (0)
0