go-vise

Constrained Size Output Virtual Machine
Info | Log | Files | Refs | README | LICENSE

signals.texi (2037B)


      1 @node signals
      2 @chapter Signal flags
      3 
      4 
      5 @section Client-defined signal flags
      6 
      7 The client can define any number of signal flags to use. The number of signals @strong{MUST} be declared explicitly in the client code, and @strong{MUST NOT} change in stateful or asynchronous execution environments.
      8 
      9 In the assembly code, signals may only be referred to by their numerical value. The numeric value of client-defined signals must have numeric value @code{8} or greater.
     10 
     11 
     12 @subsection Flow control
     13 
     14 Signal flags enables the client to control the execution flow as a side-effect of the execution of external code symbols.
     15 
     16 Branching is defined using either the @code{CATCH} or @code{CROAK} instructions.
     17 
     18 The client specifies whether or not a set flag should be reset on next yield. If not, it is the responsiblity of the client to reset the flag when necessary.
     19 
     20 
     21 @anchor{builtin_flags}
     22 @section Built-in signal flags
     23 
     24 For the numeric values of the signals, please refer to the signals appendix.
     25 
     26 @multitable @columnfractions .15 .20 .55 .10
     27 @headitem Flag name
     28 @tab Description
     29 @tab Lifetime
     30 @tab Writeable?
     31 @item @code{READIN}
     32 @tab Input is being processed. 
     33 @tab From first @code{INCMP} until: an @code{INCMP} match @emph{or} an invalid input exception is triggered.
     34 @tab no
     35 @item @code{INMATCH}
     36 @tab Input matched an @code{INCMP} instruction.
     37 @tab Next instruction.
     38 @tab no
     39 @item @code{TERMINATE}
     40 @tab Terminate execution before the following instruction.
     41 @tab Until explicit reseet.
     42 @tab no
     43 @item @code{DIRTY}
     44 @tab Rendered output is available.
     45 @tab Until output is processed.
     46 @tab no
     47 @item @code{WAIT}
     48 @tab Halt execution before the following instruction, and yield control to client.
     49 @tab Until control is yielded.
     50 @tab no
     51 @item @code{LOADFAIL}
     52 @tab An unexpected error has occurred during execution of an external code symbol.
     53 @tab Next instruction.
     54 @tab no
     55 @item @code{LANG}
     56 @tab Output from an external code symbol is a valid language code, and language should be changed accordingly.
     57 @tab Next instruction.
     58 @tab yes
     59 @end multitable