summaryrefslogtreecommitdiff
path: root/tests/micropython/import_mpy_native.py
diff options
context:
space:
mode:
authorDamien George <damien@micropython.org>2022-05-26 10:51:29 +1000
committerDamien George <damien@micropython.org>2022-06-07 13:19:55 +1000
commitb37b57821476d9ea80cdcc89d325dcabded3ffb7 (patch)
tree8be44de48aeb5b1be95a163d2bd9e20289c75c9e /tests/micropython/import_mpy_native.py
parent2111ca0b8fdcbef6177a8d37fde53085de2a798a (diff)
py/persistentcode: Remove remaining native qstr linking support.
Support for architecture-specific qstr linking was removed in d4d53e9e114d779523e382c4ea38f0398e880aae, where native code was changed to access qstr values via qstr_table. The only remaining use for the special qstr link table in persistentcode.c is to support native module written in C, linked via mpy_ld.py. But native modules can also use the standard module-level qstr_table (and obj_table) which was introduced in the .mpy file reworking in f2040bfc7ee033e48acef9f289790f3b4e6b74e5. This commit removes the remaining native qstr liking support in persistentcode.c's load_raw_code function, and adds two new relocation options for constants.qstr_table and constants.obj_table. mpy_ld.py is updated to use these relocations options instead of the native qstr link table. Signed-off-by: Damien George <damien@micropython.org>
Diffstat (limited to 'tests/micropython/import_mpy_native.py')
-rw-r--r--tests/micropython/import_mpy_native.py5
1 files changed, 1 insertions, 4 deletions
diff --git a/tests/micropython/import_mpy_native.py b/tests/micropython/import_mpy_native.py
index d7da16581..449371dda 100644
--- a/tests/micropython/import_mpy_native.py
+++ b/tests/micropython/import_mpy_native.py
@@ -74,9 +74,7 @@ user_files = {
b'\x02' # 2 children
b'\x42' # 8 bytes, no children, viper code
- b'\x00\x00\x00\x00\x00\x00' # dummy machine code
- b'\x00\x00' # slot for qstr0
- b'\x01\x0c\x0aprint\x00' # n_qstr=1, qstr0
+ b'\x00\x00\x00\x00\x00\x00\x00\x00' # dummy machine code
b'\x00' # scope_flags
b'\x43' # 8 bytes, no children, asm code
@@ -102,7 +100,6 @@ user_files = {
b'\x22' # 4 bytes, no children, viper code
b'\x00\x00\x00\x00' # dummy machine code
- b'\x00' # n_qstr=0
b'\x70' # scope_flags: VIPERBSS | VIPERRODATA | VIPERRELOC
b'\x06\x04' # rodata=6 bytes, bss=4 bytes
b'rodata' # rodata content