Additional Status Bar bargraphs

At the time of writing the embedded browser within the standard Second Life viewer and within Kokua will not display the images on this page. Please view the page in a standalone web browser instead.

The standard viewer has two bargraphs enabled by right-click and choosing ‘Show Network Graphs’ from the status bar’s menu.

From version 6.4.16 Kokua now has five bargraphs and the enabling option has been renamed Show Network/Script Graphs to reflect the new features.

The two on the left are the original two (bandwidth and packet loss). In both cases, the more bar is shown the worse things are.

The three additional bars provide easy indicators for script performance. As with the original two, the more bar is visible the worse the statistic is along with red/yellow/green colouring for severity.

The middle bar is the script run percentage. This is how much of what scripts want to do per frame is actually achieved. A score of 100% means everything that should have happened did happen. Anything lower means that scripts are not running at optimal speed. This can cause problems with timings going wrong, slow response and sometimes more serious issues when assumptions about the sequence of events inside a script are broken because of the effects of slower script execution. This bar is an inverse bar - no colouring/no bar showing means 100% script run was achieved. The more coloured bar there is the lower the script run percentage. If you hover the mouse over the bar a popup will appear containing the current value.

If the middle bar is empty all scripts are getting all the time they need. In this case, the remaining two indicators can be treated as just informational although they will give hints on likely points where performance will degrade (eg a high amount of script time or a low amount of spare time).

The next one along is script time per frame. This is how much of each frame (around 22ms) is used for scripts. The higher the number the more time is going on scripts. This is not necessarily bad in itself so long as the region is achieving 100% script run as well. However, it is an indicator of a region well loaded with scripts.

That brings us to the rightmost indicator which is frame spare time. This is how much of the frame time was not used. Again, the less you can see of this bar the better things are. A full bar means there is no spare time.

There is usually a pattern of degradation which begins with there being no spare time available in a region. The region is then forced to prioritise the time within the frame which is usually at the expense of scripts. As scripts get starved of time it becomes impossible to service everything that should happen in the frame and the script run percentage drops. If a region cannot get enough time by starving scripts other more serious signs of strain will occur such as reductions in the Frame Per Second and Time Dilation statistics.

This is most directly affected by the number of scripts (within rezzed objects and worn by avatars) but other factors can also come into play such as objects consuming a high amount of Physics frame time or various kinds of abnormal behaviour causing the region to have less time available for scripts.

However some types of region, notably Homesteads, have script throttles which cut in before the sequence of events describes above happens. In Homesteads script time will max out at around 5 or 6ms and the script run percentage will then begin dropping as script load increases despite there being a healthy amount of spare time still remaining. The type of a region can be checked by reviewing the region type in the General tab of About Land.

Each bar has two transition points where a colour change occurs. One governs the point where red switches to yellow and the other where yellow switches to green. These are preset with default values however they may also be customised in Preferences on the Kokua/Performance 2 tab. The script run percentage thresholds can be set between 0 and 100 percent and the other two between 0 and 20 msec. Although frames are generally 22-23 msec at least 2msec is normally consumed by other activities within the frame.

 

The default values can be reinstated individually by locating the appropriate control in Advanced > Show Debug Settings and locating KokuaStatGraph[PctRun|ScriptTime|SpareTime][1|2] and using the reset to default button.

 

They will also be set back to default values, along with all other customised settings, by Preferences > Setup > Reset All Settings.

The statistics can be viewed in more detail on either of the statistics floaters accessible by CTRL-SHIFT-1 for Statistics (most viewers) and CTRL-SHIFT-8 for Script Statistics (Kokua specific).

It is also possible to set various alerts and notifications around performance using the controls on Preferences/Kokua/Performance 1 & 2. These are documented here.