Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

499 VS 1661? Why performance reduced a lot when use the newest source build for esp32 port? #5673

Closed
ccccmagicboy opened this issue Feb 20, 2020 · 5 comments

Comments

@ccccmagicboy
Copy link
Contributor

Please help!
On the same hardware board and same cpu freq setting, also use upip.install("micropython-pystone_lowmem") to get the same test code, got results below:

I (20) pm_esp32: Frequency switching config: CPU_MAX: 240, APB_MAX: 240, APB_MIN: 240, Light sleep: DISABLED
MicroPython cddb90e-dirty on 2020-02-18; ESP32 module with ESP32
Type "help()" for more information.
>>>[reboot detected 0]repl is in normal command mode
[\r\x03\x03] b'\r\n>>> '
[\r\x01] b'\r\n>>> \r\nraw REPL; CTRL-B to exit\r\n>' Ready.

import machine
machine.freq(240*1000*1000)
print(machine.freq())

import network
sta_if = network.WLAN(network.STA_IF)
sta_if.active(True)
sta_if.connect('***', '***')

import upip
upip.install("micropython-pystone_lowmem")

import pystone_lowmem
pystone_lowmem.main()

Pystone(1.2) time for 500 passes = 1001ms
This machine benchmarks at 499 pystones/second

but, after load a earlier version fw from official download page, got the result below:

MicroPython v1.12 on 2019-12-20; ESP32 module with ESP32
Type "help()" for more information.
>>>[reboot detected 0]repl is in normal command mode
[\r\x03\x03] b'\r\n>>> '
[\r\x01] b'\r\n>>> \r\nraw REPL; CTRL-B to exit\r\n>' 

import machine
machine.freq(240*1000*1000)
print(machine.freq())

import network
sta_if = network.WLAN(network.STA_IF)
sta_if.active(True)
sta_if.connect('***', '***')

import upip
upip.install("micropython-pystone_lowmem")

import pystone_lowmem
pystone_lowmem.main()

Pystone(1.2) time for 500 passes = 301ms
This machine benchmarks at 1661 pystones/second

some one can help?

@jimmo
Copy link
Member

jimmo commented Feb 20, 2020

Please see #5040 (comment) for a possible explanation, but I agree that is quite dramatic. Is this a 3.3 or 4.0 build? With or without SPIRAM?

@jimmo
Copy link
Member

jimmo commented Feb 20, 2020

FWIW, on a TinyPico, I see:
master: BOARD=TINYPICO: 1385 pystones/second
master: BOARD=GENERIC: 1170 pystones/second
v1.12: BOARD=TINYPICO: 1736 pystones/second
v1.12: BOARD=GENERIC: 735 pystones/second

The first are built from source, the second two are from the downloads page.

@ccccmagicboy
Copy link
Contributor Author

ccccmagicboy commented Feb 20, 2020

@jimmo source code untouched form master branch build with IDF3 and use board GENERIC(only add some frozen modules), and another fw from download page esp32-idf3-20191220-v1.12.bin

@ccccmagicboy
Copy link
Contributor Author

test with source code which download page v1.12 used(esp32-idf3-20191220-v1.12.bin, commit id: 1f37194), the result even more lower:

Pystone(1.2) time for 500 passes = 1403ms
This machine benchmarks at 356 pystones/second

maybe it bear on my frozen modules???

@dpgeorge
Copy link
Member

This should be fixed by 549448e (pystone now gets a score of about 1800 running at 160MHz).

tannewt added a commit to tannewt/circuitpython that referenced this issue Dec 8, 2021
…-nano-rp2040-7.1.x

Add new board Maker Nano RP2040 to branch 7.1.x.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants