Brython 3.10.7 performance compared to CPython 3.11.0

User agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:104.0) Gecko/20100101 Firefox/104.0

Test Brython
(100 = CPython)
Code
simple assignment12
for i in range(1000000):
    a = 1
augmented assignment13
a = 0
for i in range(1000000):
    a += 1
augmented assignment and list append595
t = []
i = 0
while i < 100000:
    t.append(i)
    i += 1
simple assignment to float35
for i in range(1000000):
    a = 1.0
big integers310
n = 60
for i in range(10000):
    2 ** n
hash string758
for i in range(1000000):
    hash('abcdef')
build dictionary747
for i in range(1000000):
    a = {0: 0, 'a': 'a'}
build dictionary 259
d = {}
for i in range(100000):
    d[i] = i
set dictionary item71
a = {0: 0}
for i in range(1000000):
    a[0] = i
build set540
for i in range(1000000):
    a = {0, 2.7, "x"}
build list67
for i in range(1000000):
    a = [1, 2, 3]
set list item61
a = [0]
for i in range(1000000):
    a[0] = i
list slice171
a = [1, 2, 3]
for i in range(100000):
    a[:]
integer addition69
a, b, c = 1, 2, 3
for i in range(1000000):
    a + b + c
integer + float50
a, b = 1, 2.0
for i in range(1000000):
    a + b
float addition51
a, b = 1.0, 2.0
for i in range(1000000):
    a + b
string addition32
a, b, c = 'a', 'b', 'c'
for i in range(1000000):
    a + b + c
cast int to string109
for i in range(100000):
    str(i)
create function without arguments403
for i in range(1000000):
    def f():
        pass
create function, single positional argument311
for i in range(1000000):
    def f(x):
        pass
create function, complex arguments364
for i in range(1000000):
    def f(x, y=1, *args, **kw):
        pass
function call501
def f(x):
    return x
for i in range(1000000):
    f(i)
function call, complex arguments585
def f(x, y=0, *args, **kw):
    return x
for i in range(100000):
    f(i, 5, 6, a=8)
create simple class208
for i in range(10000):
    class A:
        pass
create class with init200
for i in range(10000):
    class A:
        def __init__(self, x):
            self.x = x
create instance of simple class700
class A:
    pass

for i in range(1000000):
    A()
create instance of class with init915
class A:
    def __init__(self, x):
        self.x = x

for i in range(100000):
    A(i)
call instance method1478
class A:
    def __init__(self, x):
        self.x = x

    def f(self):
        return self.x

a = A(1)
for i in range(100000):
    a.f()