Jacque-
Thursday, May 19, 2005, 8:08:54 AM, you wrote:
JLG> I think Dave's astute observation about nested repeat loops was
JLG> accurate. When I remove the "repeat 1000" loop from both your test
Yes it was. I think Dar was trying to tell me the same thing, but I
ignored it at the time.
--
-Ma
On May 19, 2005, at 1:00 AM, Mark Wieder wrote:
on mouseUp
local elapsedTime, x, y, z
put the milliseconds into elapsedTime
put the number of controls on card id 200593 of stack "revIcons"
into y
repeat 1000 times
repeat with x=1 to y
add 1 to z
end repeat
end repeat
put
Dave-
Thursday, May 19, 2005, 5:28:28 AM, you wrote:
DC> Please ignore all my previous comments on this topic. I just now paid
DC> attention to the test script. The "limit expression" is in an inner
DC> repeat loop which is within a loop that repeats 1000 times. So
DC> naturally, the expression
On 5/19/05 2:00 AM, Mark Wieder wrote:
I wrote up a new speed test here
and the loop that uses a variable seems to be running some 25 times
faster than the one that evaluates the limit each time.
I think Dave's astute observation about nested repeat loops was
accurate. When I remove the "repeat 10
Richard-
Thursday, May 19, 2005, 12:13:59 AM, you wrote:
RG> seeing, and in some ways consistent with what we would expect: how
RG> useful would it be to have a repeat loop which could affect the number
RG> of controls not counting the number of controls which govern it?
Right. So if you're not
On 19 May 2005, at 11:40, Alex Tweedly wrote:
Dave Cragg wrote:
This, combined with the slight but consistent speed advantage of
the first method when referring to fields, makes me think we need
some re- confirmation of the notion that the "limit expression" in
a repeat loop is only evalua
Dave Cragg wrote:
This, combined with the slight but consistent speed advantage of the
first method when referring to fields, makes me think we need some re-
confirmation of the notion that the "limit expression" in a repeat
loop is only evaluated once.
It is stated that way in the docs; und
On 19 May 2005, at 10:20, Dave Cragg wrote:
On 19 May 2005, at 08:00, Mark Wieder wrote:
on mouseUp
local elapsedTime, x, y, z
put the milliseconds into elapsedTime
put the number of controls on card id 200593 of stack "revIcons"
into y
repeat 1000 times
repeat with x=1 to y
add
On 19 May 2005, at 08:00, Mark Wieder wrote:
Jacque-
Wednesday, May 18, 2005, 8:03:53 PM, you wrote:
JLG> This came up on the MetaCard list back in the dark ages. Scott
Raney
JLG> said the engine figures out the variable so we don't have to,
and the
JLG> two should be identical in speed.
Maybe
Mark Wieder wrote:
Jacque-
Wednesday, May 18, 2005, 8:03:53 PM, you wrote:
JLG> This came up on the MetaCard list back in the dark ages. Scott Raney
JLG> said the engine figures out the variable so we don't have to, and the
JLG> two should be identical in speed.
Maybe I'm still in the dark ages...
Jacque-
Wednesday, May 18, 2005, 8:03:53 PM, you wrote:
JLG> This came up on the MetaCard list back in the dark ages. Scott Raney
JLG> said the engine figures out the variable so we don't have to, and the
JLG> two should be identical in speed.
Maybe I'm still in the dark ages... I wrote up a new
Dar-
Wednesday, May 18, 2005, 5:45:38 PM, you wrote:
DS> Did you forget to put the 'put' inside your timing? Or are we seeing
DS> your clock resolution?
DS> I tested two ways with Rev 2.5.1 OS X dual 1.25 GHz.
DS> I think the latter is slightly faster.
DS> Dar
Hmmm. I ran 1 iterations an
On 5/18/05 7:45 PM, Dar Scott wrote:
On May 18, 2005, at 4:31 PM, Mark Wieder wrote:
Putting the limit into a variable speeds things up considerably:
put the number of controls on card id 200593 of stack "revIcons" into y
repeat with x=1 to y
add 1 to z
end repeat
6.9 ms
Is twice as fast (.73 tic
On May 18, 2005, at 4:31 PM, Mark Wieder wrote:
Putting the limit into a variable speeds things up considerably:
put the number of controls on card id 200593 of stack "revIcons" into y
repeat with x=1 to y
add 1 to z
end repeat
6.9 ms
Is twice as fast (.73 ticks vs 1.41 ticks) as:
repeat with x=1
Mark-
Putting the limit into a variable speeds things up considerably:
put the number of controls on card id 200593 of stack "revIcons" into y
repeat with x=1 to y
add 1 to z
end repeat
Is twice as fast (.73 ticks vs 1.41 ticks) as:
repeat with x=1 to the number of controls on card id 200593 o
EMAIL PROTECTED] On Behalf Of
> Mark Smith
> Sent: Wednesday, May 18, 2005 20:05
> To: use-revolution@lists.runrev.com
> Subject: Re: 1 more speed question
>
> I put this in the script of a button:
>
> on mouseUp
>repeat 1
> add 1 to c
> put c &
Looking forward to the results of the speed test,
When it comes to the difference between case blocks and if blocks, I'll
make a prediction:
The difference will be negligible relative to the benefits of using the
most readable choice for the problem at hand.
While my experience with older xTalk
I put this in the script of a button:
on mouseUp
repeat 1
add 1 to c
put c & cr after theList
end repeat
put the milliseconds into stTime
repeat for each line L in theList
get L
end repeat
put the milliseconds - stTime into forTime
put the milliseconds into stTime
re
--- jbv <[EMAIL PROTECTED]> wrote:
>
>
> Jan,
>
> Thanks for the explanation, but as for your
> example :
>
> repeat for each line tLine in tLongList
> get tLine
> ## now do everything with it
> end repeat
>
> what if I need to replace tLine in tLongList
> after some processing on each lin
Jan,
Thanks for the explanation, but as for your
example :
repeat for each line tLine in tLongList
get tLine
## now do everything with it
end repeat
what if I need to replace tLine in tLongList
after some processing on each line ?
JB
>
> Hi JB,
>
> Rest assured that 'repeat for each' is
--- jbv <[EMAIL PROTECTED]> wrote:
> for year we've been told that
> repeat for each line j in myVar
> runs significantly faster than
> repeat for i=1 to number of lines in myVar
>
> that's true, but if you use the following
> repeat with i=1 to number of lines in myVar
> get l
On May 18, 2005, at 10:21 AM, jbv wrote:
does that mean that only the fact that each successive line
is in a variable (and hence has its content easier to access
than in a huge variable with dozens or hundreds of lines)
matters, and that it has nothing to do with the repeat
structure per se ?
Naw.
Very interessting...
Thanks JB.
Best,
Pierre
Le 18 mai 05, à 18:21, jbv a écrit :
for year we've been told that
repeat for each line j in myVar
runs significantly faster than
repeat for i=1 to number of lines in myVar
that's true, but if you use the following
repeat with i=1 to number o
for year we've been told that
repeat for each line j in myVar
runs significantly faster than
repeat for i=1 to number of lines in myVar
that's true, but if you use the following
repeat with i=1 to number of lines in myVar
get line i of myVar
and then do all your processing in
24 matches
Mail list logo