Hi Konstantin,

KK> Compare the following results:

KK> Rebol: 18 seconds

I get ~.86-.93 seconds on my P900/W2K/View-1.2.10 here for your first
test.

What do you get for this one? (I get ~.50-.56 sec for this one using
hash! and ~.36-.37 using list! -- ~.56-.58 and ~.48-.50 without
preallocating space) 

    n: 100'000
    h: make hash! n  ; []
    start: now/time/precise
    repeat i n [append h i]
    print ["Elapsed time for" n "records" (now/time/precise - start)]

FOR is a mezzanine function, so it is *much* slower than native
looping functions like REPEAT.

KK> And if remove assignment to hash table and use just empty loop body
KK> (pure speed of interpreter), then times for 10000000 (ten millions)
KK> iteration are
KK>
KK> Python: 14 seconds
KK> PHP:    17 seconds
KK> Rebol:  58 seconds

I get ~.34-.38 here, using REPEAT. Using LOOP I get ~.31.

    n: 10'000'000
    start: now/time/precise
    loop n []
    print ["Elapsed time for" n "records" (now/time/precise - start)]

I haven't looked at your DyBase interface yet, but the list! datatype
in REBOL is more suited to many inserts and removals, when compared
with hash! or block! values. You may want the hash! for lookup speed
I'm guessing though. 

-- Gregg

-- 
To unsubscribe from this list, just send an email to
[EMAIL PROTECTED] with unsubscribe as the subject.

Reply via email to