[][src]Struct lc3::VMState

pub struct VMState {
    pub register: [i16; 8],
    pub pc: u16,
    pub ir: u16,
    pub supervisor: bool,
    pub priority: u8,
    pub condition: Condition,
    pub mem: [u16; 65536],
}

A VM state.

Fields

register: [i16; 8]

General purpose registers(R0~R7)

pc: u16

Program Counter

ir: u16

Instruction Register

supervisor: bool

Supervisor mode

priority: u8

Priority Level(PL0~PL7)

condition: Condition

Condition codes

mem: [u16; 65536]

Computer memory

Methods

impl VMState[src]

pub fn psr(&self) -> u16[src]

Calculates, and returns processor state register(PSR) value.

Trait Implementations

impl Default for VMState[src]

fn default() -> Self[src]

Returns empty, zero-filled virtual machine status with default memory filled.

impl Clone for VMState[src]

fn clone_from(&mut self, source: &Self)1.0.0[src]

Performs copy-assignment from source. Read more

Auto Trait Implementations

impl Send for VMState

impl Unpin for VMState

impl Sync for VMState

impl UnwindSafe for VMState

impl RefUnwindSafe for VMState

Blanket Implementations

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]