MacOSX Performance
Karsten Wolf
karstenwo at web.de
Tue Jan 25 00:20:06 UTC 2005
Am 24.01.2005 um 22:10 schrieb John M McIntosh:
>
> On Jan 24, 2005, at 12:39 PM, Karsten Wolf wrote:
>
>>
>> Regions don't affect performance that much. Rectangles tend to grow
>> too fast. Consider two small updates: one at 0 at 0 the other at 800 at 800
>> moving 64000 pixels instead of a few.
>
> Post some sample code suggestions, and we'll compare.
> --
Hhm, my actual tests seem to make my statent an understatement. But of
course I've chosen snippets accordingly...
Here it comes:
machine TiBook 867MHz, squeak diplay:32bit mac display 32bit; updater
set to minFPS:30 maxFPS:40
the snippet:
| bic |
TimeProfileBrowser onBlock: [
bic _ Pen new.
bic color: Color yellow.
5 timesRepeat:[
Display fillBlack.
0 to: 63 do:
[:i|
bic up; goto: (16 * i)@0; down;goto: 1023@(i * 12).
bic up; goto: (1023-(16 * i))@767; down; goto: 0@(767-(i * 12)).
bic up; goto: (1023-(16 * i))@0; down; goto: 0@(i * 12).
bic up; goto: (16 * i)@767; down; goto: 1023@(767-(i * 12))
]]]
VM3.8.1b2: 16126
Using rectangles for damageCollection: 5463 msec
Using regions for damageCollection: 3156 msec
Using a list of rectangles with maximum size of 128 at 128 for caching:
2289 msec
This one requires the Commander class from the purple book (attached)
the snippet:
| bic |
TimeProfileBrowser onBlock: [
Display fillWhite.
bic _ Commander new: 8.
bic fanOut.
bic do: [:eachPen| eachPen up. eachPen go: 100. eachPen down].
bic do: [:eachPen| eachPen spiral:200 angle: 121]
]
VM3.8.1b2: 7406
Using rectangles for damageCollection: 1101 msec
Using regions for damageCollection: 539 msec
Using a list of rectangles with maximum size of 128 at 128 for caching: 328
regards
karsten
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Commander.st.gz
Type: application/x-gzip
Size: 668 bytes
Desc: not available
Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20050125/63f7544e/Commander.st.bin
-------------- next part --------------
More information about the Squeak-dev
mailing list
|