artiq/artiq
Sebastien Bourdeauducq d5795fd619 master: watchdog support
Introduces a watchdog context manager to use in the experiment code that
terminates the process with an error if it times out. The syntax is:

with self.scheduler.watchdog(20*s):
   ...

Watchdogs timers are implemented by the master process (and the worker
communicates the necessary information about them) so that they can be
enforced even if the worker crashes. They can be nested arbitrarily.
During yields, all watchdog timers for the yielding worker are
suspended [TODO]. Setting up watchdogs is not supported in kernels,
however, a kernel can be called within watchdog contexts (and terminating
the worker will terminate the kernel [TODO]).

It is possible to implement a heartbeat mechanism using a watchdog, e.g.:

for i in range(...):
    with self.scheduler.watchdog(...):
        ....

Crashes/freezes within the iterator or the loop management would not be
detected, but they should be rare enough.
2015-03-11 16:43:14 +01:00
..
coredevice language/db: remove implicit_core 2015-03-08 11:37:53 +01:00
devices language/db: remove implicit_core 2015-03-08 11:37:53 +01:00
frontend master: watchdog support 2015-03-11 16:43:14 +01:00
gateware artiqlib -> artiq.gateware 2015-03-08 11:00:24 +01:00
gui remove timeout from run_params (to be replaced by a better mechanism) 2015-03-09 10:51:32 +01:00
language move realtime result registration into dbh, simplify syntax 2015-03-08 17:27:27 +01:00
master master: watchdog support 2015-03-11 16:43:14 +01:00
protocols pc_rpc: trace support in server 2015-02-27 00:17:11 -07:00
py2llvm py2llvm: support conversion of fractions to float 2015-02-18 09:56:07 -07:00
sim language/db: remove implicit_core 2015-03-08 11:37:53 +01:00
test test: add ARTIQ_NO_PERIPHERALS environment variable to disable tests requiring non-core devices 2015-03-08 11:40:50 +01:00
transforms transforms/inline: support skipping of attr init 2015-01-29 23:48:03 +08:00
__init__.py Experiment base class, replace __artiq_unit__ with docstring 2015-03-08 15:55:30 +01:00
tools.py master: watchdog support 2015-03-11 16:43:14 +01:00