uk.ac.man.cs.rainbow.simulator
Class RASM.DeclareDeviceWithState

java.lang.Object
  |
  +--uk.ac.man.cs.rainbow.simulator.Instruction
        |
        +--uk.ac.man.cs.rainbow.simulator.RASM.DeclareDeviceWithState
All Implemented Interfaces:
Serializable
Enclosing class:
RASM

Deprecated. Use DeclareDeviceWithState

public static class RASM.DeclareDeviceWithState
extends Instruction

Associate a register with an integer value.

Declares the given register to the runtime system as being that associated with the given key (an integer) provided the key is non-zero and the system is initialising. Also, the given register is set to be the characterisation register for the current thread/device. This allows the runtime system to ask questions about the state of a given device, an operation that is needed during the characterisation of states that is performed as part of the checking of a temporal model of the system.

This instruction is only ever to be used in the standard library, as it is only ever really of use in conjunction with the runtime system anyway, as there is no general mechanism for using the information with anything other than devices (Specifically, buffers and arbitrates. All the other standard devices have no useful examinable state.) from the library.

There is a lot of overlap between declareDeviceWithState and labelDevice and the difference between them is probably a little subtle for this document. Try to describe the difference properly!

regId key -

See Also:
RASM.LabelDevice, RASM.StatelessDevice, Scheduler.readKeyedRegister(int), Serialized Form

Inner classes inherited from class uk.ac.man.cs.rainbow.simulator.Instruction
Instruction.MACRO
 
Constructor Summary
RASM.DeclareDeviceWithState()
          Deprecated.  
RASM.DeclareDeviceWithState(RASMCode code)
          Deprecated.  
 
Method Summary
protected  boolean execute(RASMThread thread)
          Deprecated. Make this instruction execute in the given context.
 String toString()
          Deprecated.  
 
Methods inherited from class uk.ac.man.cs.rainbow.simulator.Instruction
addClass, getInstruction, getInstruction, getInstruction
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

RASM.DeclareDeviceWithState

public RASM.DeclareDeviceWithState()
Deprecated. 

RASM.DeclareDeviceWithState

public RASM.DeclareDeviceWithState(RASMCode code)
Deprecated. 
Method Detail

toString

public String toString()
Deprecated. 
Overrides:
toString in class Object

execute

protected boolean execute(RASMThread thread)
                   throws RASMThread.Exception
Deprecated. 
Description copied from class: Instruction
Make this instruction execute in the given context.
Overrides:
execute in class Instruction
Following copied from class: uk.ac.man.cs.rainbow.simulator.Instruction
Throws:
RainbowException - All sorts of things can go wrong during execution...