diff options
author | Jim Mussared <jim.mussared@gmail.com> | 2021-08-16 22:43:02 +1000 |
---|---|---|
committer | Damien George <damien@micropython.org> | 2021-08-17 11:20:58 +1000 |
commit | 0c2cadf1c8c733878a5ecfe65fe339a8702f76bd (patch) | |
tree | 6450ef80c65d7e7e06caf0c772ab181cf5bbc1ef | |
parent | e25c5cb8d249c3200753199a6682bc9a028b8860 (diff) |
unix/Makefile: Disable error compression on arm-linux-gnueabi-gcc.
This compiler is unable to optimise out the giant strcmp match generated
by MP_MATCH_COMPRESSED.
See github.com/micropython/micropython/pull/7659#issuecomment-899479793
Signed-off-by: Jim Mussared <jim.mussared@gmail.com>
-rw-r--r-- | ports/unix/Makefile | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/ports/unix/Makefile b/ports/unix/Makefile index 36b6322d8..bf9d290ab 100644 --- a/ports/unix/Makefile +++ b/ports/unix/Makefile @@ -290,6 +290,17 @@ else RUN_TESTS_MPY_CROSS_FLAGS = --mpy-cross-flags='-mcache-lookup-bc' endif +ifeq ($(CROSS_COMPILE),arm-linux-gnueabi-) +# Force disable error text compression when compiling for ARM as the compiler +# cannot optimise out the giant strcmp list generated for MP_MATCH_COMPRESSED. +# Checked on: +# arm-linux-gnueabi-gcc (Ubuntu/Linaro 7.5.0-3ubuntu1~18.04) 7.5.0 +# arm-linux-gnueabi-gcc (Ubuntu 9.3.0-17ubuntu1~20.04) 9.3.0 +# See https://github.com/micropython/micropython/pull/7659 for details. +$(info Detected arm-linux-gnueabi-gcc. Disabling error message compression.) +MICROPY_ROM_TEXT_COMPRESSION = 0 +endif + include $(TOP)/py/mkrules.mk .PHONY: test test_full |