Capabilities: RTF editing, Graphs, flat-file database

Mark Smith mark at maseurope.net
Fri Jun 11 08:14:59 EDT 2004


I don't  know if this is a decent test, but this is what I got:

fld 1 contains 1000000 lines, each line consisting simply of "1".

--fld access
on mouseUp
   set cursor to watch
   put the ticks into stTime
     repeat for each line L in fld 1
       put L into p
     end repeat
   put the ticks - stTime
end mouseUp

result - 77 ticks

--custom prop access
on mouseUp
   set cursor to watch
   set the pData of this cd to fld 1
   put the ticks into stTime
     repeat for each line L in the pData of this cd
       put L into p
     end repeat
   put the ticks - stTime
end mouseUp

result - 45 ticks

--var access
on mouseUp
   set cursor to watch
   put fld 1 into vData
   put the ticks into stTime
     repeat for each line L in vData
       put L into p
     end repeat
   put the ticks - stTime
end mouseUp

result - 45 ticks


Doesn't really look like orders of magnitude difference...is the test 
OK?


Mark Smith




On 11 Jun 2004, at 05:43, use-revolution-request at lists.runrev.com wrote:

> It's been a while since I've benchmarked it, but if I recall correctly 
> I
> believe accessing a custom property is nearly as fast as a global, and
> like globals are several orders of magnitude faster than field 
> accesses.
>
> Anyone care to run a set of benchmarks on the current engine to see how
> that holds up today?
>
> -- 
>   Richard Gaskin
>   Fourth World Media Corporation



More information about the use-livecode mailing list