… | |
… | |
3607 | |
3607 | |
3608 | $RUNTIME += $TICK; |
3608 | $RUNTIME += $TICK; |
3609 | $NEXT_TICK += $TICK; |
3609 | $NEXT_TICK += $TICK; |
3610 | |
3610 | |
3611 | if ($NOW >= $NEXT_RUNTIME_WRITE) { |
3611 | if ($NOW >= $NEXT_RUNTIME_WRITE) { |
3612 | $NEXT_RUNTIME_WRITE = $NOW + 10; |
3612 | $NEXT_RUNTIME_WRITE = List::Util::max $NEXT_RUNTIME_WRITE + 10, $NOW + 5.; |
3613 | Coro::async_pool { |
3613 | Coro::async_pool { |
3614 | $Coro::current->{desc} = "runtime saver"; |
3614 | $Coro::current->{desc} = "runtime saver"; |
3615 | write_runtime |
3615 | write_runtime |
3616 | or warn "ERROR: unable to write runtime file: $!"; |
3616 | or warn "ERROR: unable to write runtime file: $!"; |
3617 | }; |
3617 | }; |