I used as abase the "benchmark" that is in the wiki: https://github.com/micropython/micropyt ... erformance
I put the following code in boot.py and then via serial console I ran benchmark():
Code: Select all
def performanceTest():
millis = pyb.millis
endTime = millis() + 10000
count = 0
while millis() < endTime:
count += 1
return count
def benchmark():
c = 0
for i in range(10):
c += performanceTest()
c = c/10
print("Avg. Count: ", c)
With the same version (git checkout v1.0) compiled with Linaro GCC 4.8 2014.01 I got an avg of: 2152395
That is 35083 iterations more. What do you think, It worth the difference? Anyone can suggest a proper benchmark?