summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
Diffstat (limited to 'tests')
-rw-r--r--tests/cmdline/cmd_parsetree.py.exp10
-rw-r--r--tests/cmdline/cmd_showbc.py.exp24
-rw-r--r--tests/cmdline/cmd_verbose.py.exp12
-rw-r--r--tests/micropython/import_mpy_native_gc.py4
-rw-r--r--tests/micropython/import_mpy_native_x64.py6
-rwxr-xr-xtests/run-tests.py4
6 files changed, 29 insertions, 31 deletions
diff --git a/tests/cmdline/cmd_parsetree.py.exp b/tests/cmdline/cmd_parsetree.py.exp
index cc8ba82c0..bee4fc99d 100644
--- a/tests/cmdline/cmd_parsetree.py.exp
+++ b/tests/cmdline/cmd_parsetree.py.exp
@@ -78,11 +78,11 @@ arg names:
45 STORE_NAME g
48 LOAD_CONST_OBJ \.\+
50 LOAD_METHOD format
-53 LOAD_NAME b (cache=0)
-57 CALL_METHOD n=1 nkw=0
-59 STORE_NAME h
-62 LOAD_CONST_NONE
-63 RETURN_VALUE
+53 LOAD_NAME b
+56 CALL_METHOD n=1 nkw=0
+58 STORE_NAME h
+61 LOAD_CONST_NONE
+62 RETURN_VALUE
mem: total=\\d\+, current=\\d\+, peak=\\d\+
stack: \\d\+ out of \\d\+
GC: total: \\d\+, used: \\d\+, free: \\d\+
diff --git a/tests/cmdline/cmd_showbc.py.exp b/tests/cmdline/cmd_showbc.py.exp
index 325efc7db..d93fd7b48 100644
--- a/tests/cmdline/cmd_showbc.py.exp
+++ b/tests/cmdline/cmd_showbc.py.exp
@@ -119,11 +119,11 @@ Raw bytecode (code_info_size=\\d\+, bytecode_size=\\d\+):
\\d\+ UNARY_OP 3
\\d\+ STORE_FAST 10
\\d\+ LOAD_DEREF 14
-\\d\+ LOAD_ATTR c (cache=0)
+\\d\+ LOAD_ATTR c
\\d\+ STORE_FAST 11
\\d\+ LOAD_FAST 11
\\d\+ LOAD_DEREF 14
-\\d\+ STORE_ATTR c (cache=0)
+\\d\+ STORE_ATTR c
\\d\+ LOAD_DEREF 14
\\d\+ LOAD_CONST_SMALL_INT 0
\\d\+ LOAD_SUBSCR
@@ -233,7 +233,7 @@ Raw bytecode (code_info_size=\\d\+, bytecode_size=\\d\+):
\\d\+ LOAD_DEREF 16
\\d\+ POP_TOP
\\d\+ JUMP \\d\+
-\\d\+ LOAD_GLOBAL y (cache=0)
+\\d\+ LOAD_GLOBAL y
\\d\+ POP_TOP
\\d\+ JUMP \\d\+
\\d\+ LOAD_DEREF 14
@@ -418,13 +418,13 @@ arg names:
(N_EXC_STACK 0)
bc=0 line=1
########
- bc=13 line=150
-00 LOAD_NAME __name__ (cache=0)
-04 STORE_NAME __module__
-07 LOAD_CONST_STRING 'Class'
-10 STORE_NAME __qualname__
-13 LOAD_CONST_NONE
-14 RETURN_VALUE
+ bc=12 line=150
+00 LOAD_NAME __name__
+03 STORE_NAME __module__
+06 LOAD_CONST_STRING 'Class'
+09 STORE_NAME __qualname__
+12 LOAD_CONST_NONE
+13 RETURN_VALUE
File cmdline/cmd_showbc.py, code block 'f' (descriptor: \.\+, bytecode @\.\+ bytes)
Raw bytecode (code_info_size=\\d\+, bytecode_size=\\d\+):
########
@@ -434,8 +434,8 @@ arg names: self
(N_EXC_STACK 0)
bc=0 line=1
bc=0 line=157
-00 LOAD_GLOBAL super (cache=0)
-\\d\+ LOAD_GLOBAL __class__ (cache=0)
+00 LOAD_GLOBAL super
+\\d\+ LOAD_GLOBAL __class__
\\d\+ LOAD_FAST 0
\\d\+ LOAD_SUPER_METHOD f
\\d\+ CALL_METHOD n=0 nkw=0
diff --git a/tests/cmdline/cmd_verbose.py.exp b/tests/cmdline/cmd_verbose.py.exp
index a2fdf1f00..0edd050c2 100644
--- a/tests/cmdline/cmd_verbose.py.exp
+++ b/tests/cmdline/cmd_verbose.py.exp
@@ -8,12 +8,12 @@ arg names:
(N_EXC_STACK 0)
bc=0 line=1
bc=0 line=3
-00 LOAD_NAME print (cache=0)
-04 LOAD_CONST_SMALL_INT 1
-05 CALL_FUNCTION n=1 nkw=0
-07 POP_TOP
-08 LOAD_CONST_NONE
-09 RETURN_VALUE
+00 LOAD_NAME print
+03 LOAD_CONST_SMALL_INT 1
+04 CALL_FUNCTION n=1 nkw=0
+06 POP_TOP
+07 LOAD_CONST_NONE
+08 RETURN_VALUE
1
mem: total=\\d\+, current=\\d\+, peak=\\d\+
stack: \\d\+ out of \\d\+
diff --git a/tests/micropython/import_mpy_native_gc.py b/tests/micropython/import_mpy_native_gc.py
index e8fac8f17..f982a4ee1 100644
--- a/tests/micropython/import_mpy_native_gc.py
+++ b/tests/micropython/import_mpy_native_gc.py
@@ -48,8 +48,8 @@ class UserFS:
# Pre-compiled examples/natmod/features0 example for various architectures, keyed
# by the required value of sys.implementation.mpy.
features0_file_contents = {
- # -march=x64 -mcache-lookup-bc
- 0xB05: b'M\x05\x0b\x1f \x84b\xe9/\x00\x00\x00SH\x8b\x1ds\x00\x00\x00\xbe\x02\x00\x00\x00\xffS\x18\xbf\x01\x00\x00\x00H\x85\xc0u\x0cH\x8bC \xbe\x02\x00\x00\x00[\xff\xe0H\x0f\xaf\xf8H\xff\xc8\xeb\xe6ATUSH\x8b\x1dA\x00\x00\x00H\x8b\x7f\x08L\x8bc(A\xff\xd4H\x8d5\x1f\x00\x00\x00H\x89\xc5H\x8b\x05-\x00\x00\x00\x0f\xb78\xffShH\x89\xefA\xff\xd4H\x8b\x03[]A\\\xc3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x05\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x90\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x84@\x12factorial\x10\x00\x00\r \x01"\x9f\x1c\x01\x1e\xff',
+ # -march=x64
+ 0xA05: b'M\x05\x0a\x1f \x84b\xe9/\x00\x00\x00SH\x8b\x1ds\x00\x00\x00\xbe\x02\x00\x00\x00\xffS\x18\xbf\x01\x00\x00\x00H\x85\xc0u\x0cH\x8bC \xbe\x02\x00\x00\x00[\xff\xe0H\x0f\xaf\xf8H\xff\xc8\xeb\xe6ATUSH\x8b\x1dA\x00\x00\x00H\x8b\x7f\x08L\x8bc(A\xff\xd4H\x8d5\x1f\x00\x00\x00H\x89\xc5H\x8b\x05-\x00\x00\x00\x0f\xb78\xffShH\x89\xefA\xff\xd4H\x8b\x03[]A\\\xc3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x05\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x90\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x84@\x12factorial\x10\x00\x00\r \x01"\x9f\x1c\x01\x1e\xff',
# -march=armv7m
0x1605: b"M\x05\x16\x1f \x84\x12\x1a\xe0\x00\x00\x13\xb5\nK\nJ{D\x9cX\x02!\xe3h\x98G\x03F\x01 3\xb9\x02!#i\x01\x93\x02\xb0\xbd\xe8\x10@\x18GXC\x01;\xf4\xe7\x00\xbfj\x00\x00\x00\x00\x00\x00\x00\xf8\xb5\tN\tK~D\xf4X@hgi\xb8G\x05F\x07K\x07I\xf2XyD\x10\x88ck\x98G(F\xb8G h\xf8\xbd6\x00\x00\x00\x00\x00\x00\x00\x04\x00\x00\x00\x1c\x00\x00\x00\x00\x00\x00\x00\x05\x00\x00\x00\x00\x00\x00\x00\x80\x00\x00\x00\x00\x00\x00\x00\x01\x84\x00\x12factorial\x10\x00\x00\r<\x01>\x9f8\x01:\xff",
}
diff --git a/tests/micropython/import_mpy_native_x64.py b/tests/micropython/import_mpy_native_x64.py
index 3e7b2058e..cad59e991 100644
--- a/tests/micropython/import_mpy_native_x64.py
+++ b/tests/micropython/import_mpy_native_x64.py
@@ -52,11 +52,11 @@ class UserFS:
# fmt: off
user_files = {
# bad architecture
- '/mod0.mpy': b'M\x05\xff\x00\x10',
+ '/mod0.mpy': b'M\x05\xfe\x00\x10',
# test loading of viper and asm
'/mod1.mpy': (
- b'M\x05\x0b\x1f\x20' # header
+ b'M\x05\x0a\x1f\x20' # header
b'\x20' # n bytes, bytecode
b'\x00\x08\x02m\x02m' # prelude
@@ -78,7 +78,7 @@ user_files = {
# test loading viper with additional scope flags and relocation
'/mod2.mpy': (
- b'M\x05\x0b\x1f\x20' # header
+ b'M\x05\x0a\x1f\x20' # header
b'\x20' # n bytes, bytecode
b'\x00\x08\x02m\x02m' # prelude
diff --git a/tests/run-tests.py b/tests/run-tests.py
index 3e97a7c87..a8a31c0ae 100755
--- a/tests/run-tests.py
+++ b/tests/run-tests.py
@@ -742,9 +742,7 @@ the last matching regex is used:
cmd_parser.add_argument(
"--via-mpy", action="store_true", help="compile .py files to .mpy first"
)
- cmd_parser.add_argument(
- "--mpy-cross-flags", default="-mcache-lookup-bc", help="flags to pass to mpy-cross"
- )
+ cmd_parser.add_argument("--mpy-cross-flags", default="", help="flags to pass to mpy-cross")
cmd_parser.add_argument(
"--keep-path", action="store_true", help="do not clear MICROPYPATH when running tests"
)