PRIMALScript 2011 - Timing and Debugging VBScript

Use this forum to ask questions after your subscription maintenance expires or before you buy. Need information on licensing or pricing? Questions about a trial version? This is the right place for you. No scripting questions, please.
Forum rules
DO NOT POST SUBSCRIPTION NUMBERS, LICENSE KEYS OR ANY OTHER LICENSING INFORMATION IN THIS FORUM.
Only the original author and our tech personnel can reply to a topic that is created in this forum. If you find a topic that relates to an issue you are having, please create a new topic and reference the other in your post.
This topic is 13 years and 3 weeks old and has exceeded the time allowed for comments. Please begin a new topic or use the search feature to find a similar but newer topic.
User avatar
drlandau
Posts: 16
Last visit: Wed Mar 09, 2011 8:08 pm

PRIMALScript 2011 - Timing and Debugging VBScript

Post by drlandau »

You can run scripts within the debugger, which is great.But is there any way to have PRIMALScript time each statement in the script, so you can easily spot which statements is the ones that you should try to optimize for faster execution?I'm thinking something along the line, that PRIMALScript would:- Time how long each line in the script (in milliseconds) takes to execute when running the script.- Afterwards show a list of the entire script execution history with all lines that have been executed listed in order of execution with the timestamp + the time spend since the previous line (so you can see which lines has used the most milliseconds).- Also show the cumulative time used for all the lines within each function (or other defined section) for each seperat run (if the functions are called many times)- And also the total time used for each function (the time consumed for all the times the function was called, put together in a total). This will greatly aid in determining which functions it makes most sense to try to optimize.Is that possible in 2011 - or is it something you have considered (or will consider)...?Thanks!Best regards,Nicolaj Rasmussen
User avatar
Alexander Riedel
Posts: 8488
Last visit: Mon Apr 15, 2024 3:28 pm
Answers: 20
Been upvoted: 37 times

PRIMALScript 2011 - Timing and Debugging VBScript

Post by Alexander Riedel »

What you are describing is called a "Profiler". We have toyed with the idea but have not made any plans to implement this.
I'll try to create a blog post about that after the 2011 release to see how the response to something like that is.
Please feel free to remind me if you don't see anything within a reasonable amount of time after the 2011 release.
Alexander Riedel
SAPIEN Technologies, Inc.
User avatar
drlandau
Posts: 16
Last visit: Wed Mar 09, 2011 8:08 pm

PRIMALScript 2011 - Timing and Debugging VBScript

Post by drlandau »

That sounds great, thanks for the info.
I haven't been able to find any VBScript performance profilers, only some for ASP and JavaScript, so without knowing, I would expect interest to be high, especially if you can make a generic profiler that supports multiple languages. It is hard - or at least very tedious - to track down performance issues in scripts where you either have may lines of code - or the same lines gets called many times over, since you have to inject many lines of debugging to catch it (at least I don't know of any better ways :-)
User avatar
FrankAndrew
Posts: 164
Last visit: Sat Apr 01, 2023 1:52 am

PRIMALScript 2011 - Timing and Debugging VBScript

Post by FrankAndrew »

I agree!
This is the BEST way to optimize ANY script.

This should help everyone to write better code and give them another GREAT reason to use PrimalScript!

I will be looking forward to this feature.
User avatar
Alexander Riedel
Posts: 8488
Last visit: Mon Apr 15, 2024 3:28 pm
Answers: 20
Been upvoted: 37 times

PRIMALScript 2011 - Timing and Debugging VBScript

Post by Alexander Riedel »

Thanks for that additional input Frank. I'll check what we can do.
Alexander Riedel
SAPIEN Technologies, Inc.
This topic is 13 years and 3 weeks old and has exceeded the time allowed for comments. Please begin a new topic or use the search feature to find a similar but newer topic.