Here's the next... How "atomic" is SYSTEM.PUT as regards interference by interrupts? In particular:
Code: Select all
(* irqICER, irqISER, irqSCBit: the ICER, ISER and bit (a SET) corresponding to the interrupt *)
PROCEDURE* PutByte*(b: BYTE);
BEGIN
SYSTEM.PUT(irqICER, irqSCBit);
txnext := (txin + 1) MOD TxBufSize;
ASSERT(txnext # txout, Error.BufferOverflow);
txBuf[txin] := b;
txin := txnext;
SYSTEM.PUT(irqISER, irqSCBit)
END PutByte;