periods
ErrorsCollection

periods

Synthesised documentation from type/Telemetry

From type/Telemetry

See Original text in context

multi sub periods--> Seq)
multi sub periods(@s --> Seq)

The periods subroutine processes an array of Telemetry objects and generates a Seq of Telemetry::Period objects out of that. It is exported by default.

.<cpu wallclock>.say for periods(@t);
 
# OUTPUT: 
# ==================== 
# (164 / 160) 
# (23 / 21) 
# (17 / 17) 
# (15 / 16) 
# (29 / 28) 

If no array is specified, it will use the internal array of snap without parameters and will reset that array upon completion (so that new snaps can be added again).

use Telemetry;
for ^5 {
    snap;
    LAST snap;
}
say .<cpu wallclock>.join(" / "for periods;
 
# OUTPUT: 
# ==================== 
# 172 / 168 
# 24 / 21 
# 17 / 18 
# 17 / 16 
# 27 / 27 

If only one snap was done, another snap will be done to create at least one Telemetry::Period object.