I have a situation where the script prior to compile runs faster "10x" than the compiled version. Never ran into this before.
Makes it kind of difficult to debug. The routine is dawing an image in the dialog box.
Anyone ever experience this?
Compiled script runs slower than script.
Moderators: Dorian (MJT support), JRL
Resolved the problem. Although I don't know why this effects the the exe file. When compiling the script I have to leave logging enabled. If I disable logging it slows the the exe.
I tested on on previuosly working exe files and the problem occurs when logging is disabled.
Does this make sense? not to me.
Can anyone shed some light on this?
I tested on on previuosly working exe files and the problem occurs when logging is disabled.
Does this make sense? not to me.
Can anyone shed some light on this?
The following script doesn't do much. It just cycles and reports the time per cycle. I do notice differences depending on how I run it. I'm in the .9s if I run from the editor and in the .7s if I run from the main menu. I'm in the .6s if I run compiled. Made many different compile option choices but did not see that any choice combination made any difference.
Perhaps you could alter this script to demonstrate where you are seeing differences based on compile options.
Perhaps you could alter this script to demonstrate where you are seeing differences based on compile options.
Code: Select all
Dialog>Dialog1
object Dialog1: TForm
Position = poScreenCenter
Caption = 'Speed Test'
ClientHeight = 158
ClientWidth = 178
object Label1: TLabel
Left = 26
Top = 16
Width = 32
Height = 13
Caption = 'Current Cycle Time'
end
object Label2: TLabel
Left = 26
Top = 80
Width = 32
Height = 13
Caption = 'Best Cycle Time'
end
object Panel1: TPanel
Left = 26
Top = 38
Width = 127
Height = 27
TabOrder = 0
end
object Panel2: TPanel
Left = 26
Top = 106
Width = 127
Height = 31
TabOrder = 1
end
end
EndDialog>Dialog1
AddDialogHandler>Dialog1,,OnClose,Quit
Let>BestTime=10000
Show>Dialog1
Label>Start
Timer>StartTime
Let>kk=0
Repeat>kk
Add>kk,1
Until>kk=10000
Timer>EndTime
Let>CycleTime={(%EndTime%-%StartTime%)/1000}
SetDialogProperty>Dialog1,Panel1,Caption,CycleTime
If>%BestTime%>%CycleTime%
Let>BestTime=CycleTime
SetDialogProperty>Dialog1,Panel2,Caption,BestTime
EndIf
Goto>Start
SRT>Quit
Exit>0
END>Quit
Hi JRL,
I had forgoten about the timer function, thanks for the reminder.
After a few hours testing I found that the problem does not occur when data is generated with in the script.
when I create array of data points using MS array functions it works quite well. The results are similar to what you experienced.
However I believe ( not proven but further testing required) when I use Vbscript to read a file into a multidemensional array and then use VBEval calls to retrieve the array variables the problem occurs.
As I was able to compile and run one of the old test files. The one we used for the rotation problem you helped me with.
It works just fine. In that file all the data was created within MS.
I can not post the entire script. When I get a working example that I can post I will.
Thanks
I had forgoten about the timer function, thanks for the reminder.
After a few hours testing I found that the problem does not occur when data is generated with in the script.
when I create array of data points using MS array functions it works quite well. The results are similar to what you experienced.
However I believe ( not proven but further testing required) when I use Vbscript to read a file into a multidemensional array and then use VBEval calls to retrieve the array variables the problem occurs.
As I was able to compile and run one of the old test files. The one we used for the rotation problem you helped me with.
It works just fine. In that file all the data was created within MS.
I can not post the entire script. When I get a working example that I can post I will.
Thanks