ghp
Posts: 1418
Joined: Wed Jun 12, 2013 12:41 pm
Location: Stuttgart Germany
Contact: Website

scratch3 performance comparison

Wed Aug 21, 2019 2:14 pm

Had a walk through cambridge today and found first and only raspberry pi shop.
Bought a pi4, 4gb. Installed scratch3, network is nice and fast here in hotel.

Did a few performance tests (using VNC connection), using scratch3 and scatch1.4

- for two sprites, rotate 1 degree, for 10 sec. scratch 3: 303 rotations, scratch 1: 460 (larger is better)

- for two sprites, place to opposite corners. Let them move one step
towards the other till reaching the other corner. They meet in the middle and continue till other corner.
scratch 3: 13.2 sec, scratch 1: 8.7 sec (smaller is better)

- the pingpong game: one sprite sends ping, when the other receives ping it
sends pong which the first one responds to again with -guess- ping.
scratch3 302000 in 10 secs, this varies a bit. scratch1 231 in 10 secs. This was
similiar to scratch2. Event performance is snail-like in scratch1.

These results are similiar to those in scratch2.
Last edited by ghp on Sat Sep 14, 2019 9:26 am, edited 1 time in total.

spl23
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 378
Joined: Fri Dec 26, 2014 11:02 am

Re: scratch3 performance comparison

Thu Aug 22, 2019 6:51 am

Hardly surprising. Scratch 1 is far more efficiently implemented than Scratch 2 or 3; it's not native code, but is running as Smalltalk code on an efficient interpreter which is optimised for the platform. Both Scratch 2 and Scratch 3 are effectively just packaged versions of the website code for each, running in an application based on the Chromium browser (and in the case of Scratch 2, using Adobe's Flash as well) - there's an awful lot more overhead when doing that than for Scratch 1.

Which is why we still offer Scratch 1 - it will run faster, particularly on low-end Pis. MIT have never made a real native version of Scratch 2 or 3 available, because it would be a huge amount of work to do so, so the packaged web code is the best we can do.

Return to “Scratch”