isa

package
v0.0.0-...-bcc578f Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 5, 2022 License: Apache-2.0 Imports: 3 Imported by: 0

README

Instruction Set Architecture

32-bit instructions

LoadConstant: 1CCCCCCC CCCCCCCC CCCCCCCC CCCDDDDD Jump: 01CCBOOO OOOOOOOO OOOOOOOO OOORRRRR Load/Store: 001TTOOO OOOOOOOO OOOOOOAA AAARRRRR Bitwise & Arithmetic: 0001TTTT -------- -2222211 111DDDDD Reserved: 00001--- -------- -------- -------- Push/Pop: 000001T- -------- MMMMMMMM MMMMMMMM Call: 00000010 -------- -------- ---AAAAA Return: 00000011 -------- -------- -------- Special: 00000001 TTTT---- -------- --------

Bitwise

Assembly: operation source1 source2 destination Opcode: 00010TTT -------- -2222211 111DDDDD

T: type;

  • 000 - Not
  • 001 - And
  • 010 - Or
  • 011 - Xor
  • 100 - Left Shift
  • 101 - Right Shift
  • 110 - Reserved
  • 111 - Reserved

1: first source register

2: second source register

D: destination register

Not

Performs a bitwise not.

register[destination] = !register[source1]
And

Performs a bitwise and.

register[destination] = register[source1] & register[source2]
Or

Performs a bitwise or.

register[destination] = register[source1] | register[source2]
Xor

Performs a bitwise xor.

register[destination] = register[source1] ^ register[source2]
Left Shift

Performs a left logical shift.

register[destination] = register[source1] << register[source2]
Right Shift

Performs a right logical shift.

register[destination] = register[source1] >> register[source2]

Arithmetic

Assembly: operation source1 source2 destination Opcode: 00011TTT -------- -2222211 111DDDDD

T: type;

  • 000 - Add
  • 001 - Subtract
  • 010 - Multiply
  • 011 - Divide
  • 100 - Modulo
  • 101 - Reserved
  • 110 - Reserved
  • 111 - Reserved

1: first source register

2: second source register

D: destination register

Add

Performs an addition.

register[destination] = register[source1] + register[source2]
Subtract

Performs a subtraction.

register[destination] = register[source1] - register[source2]
Multiply

Performs a multiplication.

register[destination] = register[source1] * register[source2]
Divide

Performs a division.

register[destination] = register[source1] / register[source2]

Triggers InterruptArithmeticError if contents of source2 is 0.

Modulo

Performs a modulo.

register[destination] = register[source1] % register[source2]

Triggers InterruptArithmeticError if contents of source2 is 0.

Control Flow

Jump

Assembly: operation conditional addressoffset Opcode: 01CCBOOO OOOOOOOO OOOOOOOO OOORRRRR

C: conditioncode:

  • 00: ez: jump if regster[conditional] is equal to zero (all bits zero)
  • 01: nz: jump if regster[conditional] is not equal to zero (not all bits zero)
  • 10: le: jump if regster[conditional] is less than or equal to zero (most significant bit set or all bits zero)
  • 11: lz: jump if regster[conditional] is less than zero (most significant bit set)

R: conditional register

B: backwards

  • set if addressoffset should be subtracted from programcounter

O: addressoffset

  • 22bit
if condition {
    if backwards {
        programcounter = programcounter - addressoffset
    } else {
        programcounter = programcounter + addressoffset
    }
}
Call

Assembly: call addressregister Opcode: 00000010 -------- -------- ---AAAAA

A: address register

stack[stackpointer] = programcounter + instructionsize
stackpointer += datasize
programcounter = register[address]

Pushes the address of the next instruction (sum of RProgramCounter and InstructionSize) onto the stack.

Sets RProgramCounter to the contents of address register.

Calling Convention
  • Callers are responsible for saving all general purpose registers in use to the stack using 'push' before calling the function.

  • Callers are responsible for restoring all general purpose registers in use from the stack using 'pop' after the function returns.

  • Callers may pass parameters to the function using the general purpose registers (r16 is parameter 1, r17 is parameter 2, ..., r30 is parameter 15). If the number of parameters exceeds 15 they should be written to a region of memory and the address to which is passed as parameter 1 (r16).

  • Callers load the function address into a register (typically r31) and then call it (eg 'call r31'). The address of the instruction after the call will be pushed onto the stack.

  • Functions receive their parameters through the general purpose registers.

  • Functions may return values through the general purpose registers (r16 is return value 1, r17 is return value 2, ..., r30 is return value 15). If the number of return values exceeds 15 they should be written to a region of memory and the address to which is passed as return value 1 (r16).

  • Functions exit and return control flow to the caller using the 'return' instruction, which pops the return address off the stack and into the program counter register.

Example

loadc 1 r16                         // A general purpose registers in use
loadc 2 r17                         // A general purpose registers in use
loadc 3 r18                         // A general purpose registers in use
loadc 4 r19                         // A general purpose registers in use

push r16,r17,r18,r19                // Caller saves all general purpose registers in use to the stack
loadc 8 r16                         // Caller passes parameters using the general purpose registers
loadc #Square r31                   // Caller loads function address
call r31                            // Caller calls function
copy r16 r20                        // Caller receives return value using the general purpose registers
pop r19,r18,r17,r16                 // Caller restores all general purpose registers in use from the stack
halt

// Expected Register Value
// - r16 1
// - r17 2
// - r18 3
// - r19 4
// - r20 64

#Square                             // A function to return the square of the given parameter
multiply r16 r16 r16                // Receive parameter from r16 and return value to r16
return                              // Return control flow to caller
Return

Assembly: return Opcode: 00000011 -------- -------- --------

stackpointer -= datasize
programcounter = stack[stackpointer]

Pops the return address off the stack.

Sets RProgramCounter to the return address.

Data Movement

Load Constant

Assembly: loadc destination constant Opcode: 1CCCCCCC CCCCCCCC CCCCCCCC CCCDDDDD

D: destination register

C: constant

  • 26bit
register[destination] = constant
Load

Assembly: load address offset destination Opcode: 00100OOO OOOOOOOO OOOOOOAA AAARRRRR

A: address register

O: offset

  • 17bit

D: destination register

register[destination] = memory[register[address] + offset]

Retryable if L1 Data Cache is unavailable or unsuccessful (cache miss).

Store

Assembly: store address offset source Opcode: 00101OOO OOOOOOOO OOOOOOAA AAASSSSS

A: address register

O: offset

  • 17bit

S: source register

memory[register[address] + offset] = register[source]

Retryable if L1 Data Cache is unavailable or unsuccessful (cache miss).

Clear

Assembly: clear address offset Opcode: 00110OOO OOOOOOOO OOOOOOAA AAA00000

A: address register

O: offset

  • 17bit

Invalidates the data stored in the cache(s) at the address, forcing the next load to come from main memory.

Retryable if L1 Instruction, L1 Data, or L2 Cache is unavailable or unsuccessful (cache miss).

Flush

Assembly: flush address offset Opcode: 00111OOO OOOOOOOO OOOOOOAA AAA00000

A: address register

O: offset

  • 17bit

Writes the data stored in the cache(s) at the address to main memory.

Retryable if L1 Data, or L2 Cache is unavailable or unsuccessful (cache miss).

Push

Assembly: push register Opcode: 0000010- -------- MMMMMMMM MMMMMMMM

M: register mask

Pushes the given registers onto stack.

Retryable while each register in mask is pushed.

Retryable if L1 Data Cache is unavailable or unsuccessful (cache miss).

Triggers InterruptStackOverflowError if RStackPointer > RStackLimit.

Pop

Assembly: pop register Opcode: 0000011- -------- MMMMMMMM MMMMMMMM

M: register mask

Pops the given registers from stack.

Retryable while each register in mask is popped.

Retryable if L1 Data Cache is unavailable or unsuccessful (cache miss).

Triggers InterruptStackUnderflowError if RStackPointer < RStackStart.

Special

Halt

Assembly: halt Opcode: 00000001 0000---- -------- --------

Halts the processor.

Only callable during an interrupt - triggers InterruptUnsupportedOperationError otherwise.

Noop

Assembly: noop Opcode: 00000001 0001---- -------- --------

Does nothing

Sleep

Assembly: sleep Opcode: 00000001 0010---- -------- --------

Puts the processor to sleep, to be awoken by the next signal.

Only callable during an interrupt - triggers InterruptUnsupportedOperationError otherwise.

Takes context out of interrupted state as only an uninterrupted context can be interrupted.

Signal

Assembly: signal device Opcode: 00000001 0011---- -------- ---DDDDD

D: device register

Sends a signal the given device.

Device addressing;

  • 0-7 core
  • 8-65535 io device

Only callable during an interrupt - triggers InterruptUnsupportedOperationError otherwise.

Lock

Assembly: lock Opcode: 00000001 0100---- -------- --------

Acquires the hardware lock.

Only callable during an interrupt - triggers InterruptUnsupportedOperationError otherwise.

Retryable if lock is not acquired.

Unlock

Assembly: unlock Opcode: 00000001 0101---- -------- --------

Releases the hardware lock.

Only callable during an interrupt - triggers InterruptUnsupportedOperationError otherwise.

Retryable if lock is not released.

Interrupt

Assembly: interrupt addressregister Opcode: 00000001 0110---- IIIIIIII IIIIIIII

I: interrupt identifier

  • 16bit
programcounter = interruptvectortable + interruptidentifier
Uninterrupt

Assembly: uninterrupt addressregister Opcode: 00000001 0111---- -------- 000AAAAA

A: address register

programcounter = register[address]

Only callable during an interrupt - triggers InterruptUnsupportedOperationError otherwise.

Documentation

Index

Constants

View Source
const (
	Width1Bit  = 0x1
	Width2Bit  = 0x3
	Width4Bit  = 0xF
	Width5Bit  = 0x1F
	Width8Bit  = 0xFF
	Width10Bit = 0x3FF
	Width16Bit = 0xFFFF
	Width17Bit = 0x1FFFF
	Width22Bit = 0x3FFFFF
	Width26Bit = 0x3FFFFFF

	WidthRegister = Width5Bit
)

Variables

This section is empty.

Functions

func Decode

func Decode(opcode uint32) flamego.Instruction

func Encode

func Encode(instruction flamego.Instruction) uint32

Types

type Add

type Add struct {
	Source1Register     flamego.Register
	Source2Register     flamego.Register
	DestinationRegister flamego.Register
}

func NewAdd

func NewAdd(s1, s2, d flamego.Register) *Add

func (*Add) Execute

func (i *Add) Execute(x flamego.Context, a, b, c, d uint64) (uint64, uint64)

func (*Add) Format

func (i *Add) Format(x flamego.Context, a, b uint64) (uint64, uint64)

func (*Add) Load

func (i *Add) Load(x flamego.Context) (uint64, uint64, uint64, uint64)

func (*Add) Retire

func (i *Add) Retire(x flamego.Context) bool

func (*Add) Store

func (i *Add) Store(x flamego.Context, a, b uint64)

func (*Add) String

func (i *Add) String() string

type And

type And struct {
	Source1Register     flamego.Register
	Source2Register     flamego.Register
	DestinationRegister flamego.Register
}

func NewAnd

func NewAnd(s1, s2, d flamego.Register) *And

func (*And) Execute

func (i *And) Execute(x flamego.Context, a, b, c, d uint64) (uint64, uint64)

func (*And) Format

func (i *And) Format(x flamego.Context, a, b uint64) (uint64, uint64)

func (*And) Load

func (i *And) Load(x flamego.Context) (uint64, uint64, uint64, uint64)

func (*And) Retire

func (i *And) Retire(x flamego.Context) bool

func (*And) Store

func (i *And) Store(x flamego.Context, a, b uint64)

func (*And) String

func (i *And) String() string

type Call

type Call struct {
	AddressRegister flamego.Register
	// contains filtered or unexported fields
}

func NewCall

func NewCall(a flamego.Register) *Call

func (*Call) Execute

func (i *Call) Execute(x flamego.Context, a, b, c, d uint64) (uint64, uint64)

func (*Call) Format

func (i *Call) Format(x flamego.Context, a, b uint64) (uint64, uint64)

func (*Call) Load

func (i *Call) Load(x flamego.Context) (uint64, uint64, uint64, uint64)

func (*Call) Retire

func (i *Call) Retire(x flamego.Context) bool

func (*Call) Store

func (i *Call) Store(x flamego.Context, a, b uint64)

func (*Call) String

func (i *Call) String() string

type Clear

type Clear struct {
	AddressRegister flamego.Register
	Offset          uint32
	// contains filtered or unexported fields
}

func NewClear

func NewClear(a flamego.Register, o uint32) *Clear

func (*Clear) Execute

func (i *Clear) Execute(x flamego.Context, a, b, c, d uint64) (uint64, uint64)

func (*Clear) Format

func (i *Clear) Format(x flamego.Context, a, b uint64) (uint64, uint64)

func (*Clear) Load

func (i *Clear) Load(x flamego.Context) (uint64, uint64, uint64, uint64)

func (*Clear) Retire

func (i *Clear) Retire(x flamego.Context) bool

func (*Clear) Store

func (i *Clear) Store(x flamego.Context, a, b uint64)

func (*Clear) String

func (i *Clear) String() string

type Divide

type Divide struct {
	Source1Register     flamego.Register
	Source2Register     flamego.Register
	DestinationRegister flamego.Register
}

func NewDivide

func NewDivide(s1, s2, d flamego.Register) *Divide

func (*Divide) Execute

func (i *Divide) Execute(x flamego.Context, a, b, c, d uint64) (uint64, uint64)

func (*Divide) Format

func (i *Divide) Format(x flamego.Context, a, b uint64) (uint64, uint64)

func (*Divide) Load

func (i *Divide) Load(x flamego.Context) (uint64, uint64, uint64, uint64)

func (*Divide) Retire

func (i *Divide) Retire(x flamego.Context) bool

func (*Divide) Store

func (i *Divide) Store(x flamego.Context, a, b uint64)

func (*Divide) String

func (i *Divide) String() string

type Flush

type Flush struct {
	AddressRegister flamego.Register
	Offset          uint32
	// contains filtered or unexported fields
}

func NewFlush

func NewFlush(a flamego.Register, o uint32) *Flush

func (*Flush) Execute

func (i *Flush) Execute(x flamego.Context, a, b, c, d uint64) (uint64, uint64)

func (*Flush) Format

func (i *Flush) Format(x flamego.Context, a, b uint64) (uint64, uint64)

func (*Flush) Load

func (i *Flush) Load(x flamego.Context) (uint64, uint64, uint64, uint64)

func (*Flush) Retire

func (i *Flush) Retire(x flamego.Context) bool

func (*Flush) Store

func (i *Flush) Store(x flamego.Context, a, b uint64)

func (*Flush) String

func (i *Flush) String() string

type Halt

type Halt struct {
	// contains filtered or unexported fields
}

func NewHalt

func NewHalt() *Halt

func (*Halt) Execute

func (i *Halt) Execute(x flamego.Context, a, b, c, d uint64) (uint64, uint64)

func (*Halt) Format

func (i *Halt) Format(x flamego.Context, a, b uint64) (uint64, uint64)

func (*Halt) Load

func (i *Halt) Load(x flamego.Context) (uint64, uint64, uint64, uint64)

func (*Halt) Retire

func (i *Halt) Retire(x flamego.Context) bool

func (*Halt) Store

func (i *Halt) Store(x flamego.Context, a, b uint64)

func (*Halt) String

func (i *Halt) String() string

type Interrupt

type Interrupt struct {
	Value flamego.InterruptValue
}

func NewInterrupt

func NewInterrupt(value flamego.InterruptValue) *Interrupt

func (*Interrupt) Execute

func (i *Interrupt) Execute(x flamego.Context, a, b, c, d uint64) (uint64, uint64)

func (*Interrupt) Format

func (i *Interrupt) Format(x flamego.Context, a, b uint64) (uint64, uint64)

func (*Interrupt) Load

func (*Interrupt) Retire

func (i *Interrupt) Retire(x flamego.Context) bool

func (*Interrupt) Store

func (i *Interrupt) Store(x flamego.Context, a, b uint64)

func (*Interrupt) String

func (i *Interrupt) String() string

type Jump

type Jump struct {
	ConditionCode     JumpConditionCode
	Direction         JumpDirection
	Offset            uint32
	ConditionRegister flamego.Register
}

func (*Jump) Execute

func (i *Jump) Execute(x flamego.Context, a, b, c, d uint64) (uint64, uint64)

func (*Jump) Format

func (i *Jump) Format(x flamego.Context, a, b uint64) (uint64, uint64)

func (*Jump) Load

func (i *Jump) Load(x flamego.Context) (uint64, uint64, uint64, uint64)

func (*Jump) Retire

func (i *Jump) Retire(x flamego.Context) bool

func (*Jump) Store

func (i *Jump) Store(x flamego.Context, a, b uint64)

func (*Jump) String

func (i *Jump) String() string

type JumpConditionCode

type JumpConditionCode uint8
const (
	JumpEZ JumpConditionCode = iota
	JumpNZ
	JumpLE
	JumpLZ
)

func (JumpConditionCode) String

func (i JumpConditionCode) String() string

type JumpDirection

type JumpDirection bool
const (
	JumpForward  JumpDirection = false
	JumpBackward JumpDirection = true
)

func (JumpDirection) String

func (i JumpDirection) String() string

type LeftShift

type LeftShift struct {
	Source1Register     flamego.Register
	Source2Register     flamego.Register
	DestinationRegister flamego.Register
}

func NewLeftShift

func NewLeftShift(s1, s2, d flamego.Register) *LeftShift

func (*LeftShift) Execute

func (i *LeftShift) Execute(x flamego.Context, a, b, c, d uint64) (uint64, uint64)

func (*LeftShift) Format

func (i *LeftShift) Format(x flamego.Context, a, b uint64) (uint64, uint64)

func (*LeftShift) Load

func (*LeftShift) Retire

func (i *LeftShift) Retire(x flamego.Context) bool

func (*LeftShift) Store

func (i *LeftShift) Store(x flamego.Context, a, b uint64)

func (*LeftShift) String

func (i *LeftShift) String() string

type Load

type Load struct {
	AddressRegister     flamego.Register
	Offset              uint32
	DestinationRegister flamego.Register
	// contains filtered or unexported fields
}

func NewLoad

func NewLoad(a flamego.Register, o uint32, r flamego.Register) *Load

func (*Load) Execute

func (i *Load) Execute(x flamego.Context, a, b, c, d uint64) (uint64, uint64)

func (*Load) Format

func (i *Load) Format(x flamego.Context, a, b uint64) (uint64, uint64)

func (*Load) Load

func (i *Load) Load(x flamego.Context) (uint64, uint64, uint64, uint64)

func (*Load) Retire

func (i *Load) Retire(x flamego.Context) bool

func (*Load) Store

func (i *Load) Store(x flamego.Context, a, b uint64)

func (*Load) String

func (i *Load) String() string

type LoadC

type LoadC struct {
	Constant            uint32
	DestinationRegister flamego.Register
}

func NewLoadC

func NewLoadC(c uint32, r flamego.Register) *LoadC

func (*LoadC) Execute

func (i *LoadC) Execute(x flamego.Context, a, b, c, d uint64) (uint64, uint64)

func (*LoadC) Format

func (i *LoadC) Format(x flamego.Context, a, b uint64) (uint64, uint64)

func (*LoadC) Load

func (i *LoadC) Load(x flamego.Context) (uint64, uint64, uint64, uint64)

func (*LoadC) Retire

func (i *LoadC) Retire(x flamego.Context) bool

func (*LoadC) Store

func (i *LoadC) Store(x flamego.Context, a, b uint64)

func (*LoadC) String

func (i *LoadC) String() string

type Lock

type Lock struct {
	// contains filtered or unexported fields
}

func NewLock

func NewLock() *Lock

func (*Lock) Execute

func (i *Lock) Execute(x flamego.Context, a, b, c, d uint64) (uint64, uint64)

func (*Lock) Format

func (i *Lock) Format(x flamego.Context, a, b uint64) (uint64, uint64)

func (*Lock) Load

func (i *Lock) Load(x flamego.Context) (uint64, uint64, uint64, uint64)

func (*Lock) Retire

func (i *Lock) Retire(x flamego.Context) bool

func (*Lock) Store

func (i *Lock) Store(x flamego.Context, a, b uint64)

func (*Lock) String

func (i *Lock) String() string

type Modulo

type Modulo struct {
	Source1Register     flamego.Register
	Source2Register     flamego.Register
	DestinationRegister flamego.Register
}

func NewModulo

func NewModulo(s1, s2, d flamego.Register) *Modulo

func (*Modulo) Execute

func (i *Modulo) Execute(x flamego.Context, a, b, c, d uint64) (uint64, uint64)

func (*Modulo) Format

func (i *Modulo) Format(x flamego.Context, a, b uint64) (uint64, uint64)

func (*Modulo) Load

func (i *Modulo) Load(x flamego.Context) (uint64, uint64, uint64, uint64)

func (*Modulo) Retire

func (i *Modulo) Retire(x flamego.Context) bool

func (*Modulo) Store

func (i *Modulo) Store(x flamego.Context, a, b uint64)

func (*Modulo) String

func (i *Modulo) String() string

type Multiply

type Multiply struct {
	Source1Register     flamego.Register
	Source2Register     flamego.Register
	DestinationRegister flamego.Register
}

func NewMultiply

func NewMultiply(s1, s2, d flamego.Register) *Multiply

func (*Multiply) Execute

func (i *Multiply) Execute(x flamego.Context, a, b, c, d uint64) (uint64, uint64)

func (*Multiply) Format

func (i *Multiply) Format(x flamego.Context, a, b uint64) (uint64, uint64)

func (*Multiply) Load

func (i *Multiply) Load(x flamego.Context) (uint64, uint64, uint64, uint64)

func (*Multiply) Retire

func (i *Multiply) Retire(x flamego.Context) bool

func (*Multiply) Store

func (i *Multiply) Store(x flamego.Context, a, b uint64)

func (*Multiply) String

func (i *Multiply) String() string

type Noop

type Noop struct {
}

func NewNoop

func NewNoop() *Noop

func (*Noop) Execute

func (i *Noop) Execute(x flamego.Context, a, b, c, d uint64) (uint64, uint64)

func (*Noop) Format

func (i *Noop) Format(x flamego.Context, a, b uint64) (uint64, uint64)

func (*Noop) Load

func (i *Noop) Load(x flamego.Context) (uint64, uint64, uint64, uint64)

func (*Noop) Retire

func (i *Noop) Retire(x flamego.Context) bool

func (*Noop) Store

func (i *Noop) Store(x flamego.Context, a, b uint64)

func (*Noop) String

func (i *Noop) String() string

type Not

type Not struct {
	SourceRegister      flamego.Register
	DestinationRegister flamego.Register
}

func NewNot

func NewNot(s, d flamego.Register) *Not

func (*Not) Execute

func (i *Not) Execute(x flamego.Context, a, b, c, d uint64) (uint64, uint64)

func (*Not) Format

func (i *Not) Format(x flamego.Context, a, b uint64) (uint64, uint64)

func (*Not) Load

func (i *Not) Load(x flamego.Context) (uint64, uint64, uint64, uint64)

func (*Not) Retire

func (i *Not) Retire(x flamego.Context) bool

func (*Not) Store

func (i *Not) Store(x flamego.Context, a, b uint64)

func (*Not) String

func (i *Not) String() string

type Or

type Or struct {
	Source1Register     flamego.Register
	Source2Register     flamego.Register
	DestinationRegister flamego.Register
}

func NewOr

func NewOr(s1, s2, d flamego.Register) *Or

func (*Or) Execute

func (i *Or) Execute(x flamego.Context, a, b, c, d uint64) (uint64, uint64)

func (*Or) Format

func (i *Or) Format(x flamego.Context, a, b uint64) (uint64, uint64)

func (*Or) Load

func (i *Or) Load(x flamego.Context) (uint64, uint64, uint64, uint64)

func (*Or) Retire

func (i *Or) Retire(x flamego.Context) bool

func (*Or) Store

func (i *Or) Store(x flamego.Context, a, b uint64)

func (*Or) String

func (i *Or) String() string

type Pop

type Pop struct {
	Mask uint16
	// contains filtered or unexported fields
}

func NewPop

func NewPop(m uint16) *Pop

func (*Pop) Execute

func (i *Pop) Execute(x flamego.Context, a, b, c, d uint64) (uint64, uint64)

func (*Pop) Format

func (i *Pop) Format(x flamego.Context, a, b uint64) (uint64, uint64)

func (*Pop) Load

func (i *Pop) Load(x flamego.Context) (uint64, uint64, uint64, uint64)

func (*Pop) Retire

func (i *Pop) Retire(x flamego.Context) bool

func (*Pop) Store

func (i *Pop) Store(x flamego.Context, a, b uint64)

func (*Pop) String

func (i *Pop) String() string

type Push

type Push struct {
	Mask uint16
	// contains filtered or unexported fields
}

func NewPush

func NewPush(m uint16) *Push

func (*Push) Execute

func (i *Push) Execute(x flamego.Context, a, b, c, d uint64) (uint64, uint64)

func (*Push) Format

func (i *Push) Format(x flamego.Context, a, b uint64) (uint64, uint64)

func (*Push) Load

func (i *Push) Load(x flamego.Context) (uint64, uint64, uint64, uint64)

func (*Push) Retire

func (i *Push) Retire(x flamego.Context) bool

func (*Push) Store

func (i *Push) Store(x flamego.Context, a, b uint64)

func (*Push) String

func (i *Push) String() string

type Return

type Return struct {
	// contains filtered or unexported fields
}

func NewReturn

func NewReturn() *Return

func (*Return) Execute

func (i *Return) Execute(x flamego.Context, a, b, c, d uint64) (uint64, uint64)

func (*Return) Format

func (i *Return) Format(x flamego.Context, a, b uint64) (uint64, uint64)

func (*Return) Load

func (i *Return) Load(x flamego.Context) (uint64, uint64, uint64, uint64)

func (*Return) Retire

func (i *Return) Retire(x flamego.Context) bool

func (*Return) Store

func (i *Return) Store(x flamego.Context, a, b uint64)

func (*Return) String

func (i *Return) String() string

type RightShift

type RightShift struct {
	Source1Register     flamego.Register
	Source2Register     flamego.Register
	DestinationRegister flamego.Register
}

func NewRightShift

func NewRightShift(s1, s2, d flamego.Register) *RightShift

func (*RightShift) Execute

func (i *RightShift) Execute(x flamego.Context, a, b, c, d uint64) (uint64, uint64)

func (*RightShift) Format

func (i *RightShift) Format(x flamego.Context, a, b uint64) (uint64, uint64)

func (*RightShift) Load

func (*RightShift) Retire

func (i *RightShift) Retire(x flamego.Context) bool

func (*RightShift) Store

func (i *RightShift) Store(x flamego.Context, a, b uint64)

func (*RightShift) String

func (i *RightShift) String() string

type Signal

type Signal struct {
	DeviceIdRegister flamego.Register
	// contains filtered or unexported fields
}

func NewSignal

func NewSignal(r flamego.Register) *Signal

func (*Signal) Execute

func (i *Signal) Execute(x flamego.Context, a, b, c, d uint64) (uint64, uint64)

func (*Signal) Format

func (i *Signal) Format(x flamego.Context, a, b uint64) (uint64, uint64)

func (*Signal) Load

func (i *Signal) Load(x flamego.Context) (uint64, uint64, uint64, uint64)

func (*Signal) Retire

func (i *Signal) Retire(x flamego.Context) bool

func (*Signal) Store

func (i *Signal) Store(x flamego.Context, a, b uint64)

func (*Signal) String

func (i *Signal) String() string

type Sleep

type Sleep struct {
	// contains filtered or unexported fields
}

func NewSleep

func NewSleep() *Sleep

func (*Sleep) Execute

func (i *Sleep) Execute(x flamego.Context, a, b, c, d uint64) (uint64, uint64)

func (*Sleep) Format

func (i *Sleep) Format(x flamego.Context, a, b uint64) (uint64, uint64)

func (*Sleep) Load

func (i *Sleep) Load(x flamego.Context) (uint64, uint64, uint64, uint64)

func (*Sleep) Retire

func (i *Sleep) Retire(x flamego.Context) bool

func (*Sleep) Store

func (i *Sleep) Store(x flamego.Context, a, b uint64)

func (*Sleep) String

func (i *Sleep) String() string

type Store

type Store struct {
	AddressRegister flamego.Register
	Offset          uint32
	SourceRegister  flamego.Register
	// contains filtered or unexported fields
}

func NewStore

func NewStore(a flamego.Register, o uint32, r flamego.Register) *Store

func (*Store) Execute

func (i *Store) Execute(x flamego.Context, a, b, c, d uint64) (uint64, uint64)

func (*Store) Format

func (i *Store) Format(x flamego.Context, a, b uint64) (uint64, uint64)

func (*Store) Load

func (i *Store) Load(x flamego.Context) (uint64, uint64, uint64, uint64)

func (*Store) Retire

func (i *Store) Retire(x flamego.Context) bool

func (*Store) Store

func (i *Store) Store(x flamego.Context, a, b uint64)

func (*Store) String

func (i *Store) String() string

type Subtract

type Subtract struct {
	Source1Register     flamego.Register
	Source2Register     flamego.Register
	DestinationRegister flamego.Register
}

func NewSubtract

func NewSubtract(s1, s2, d flamego.Register) *Subtract

func (*Subtract) Execute

func (i *Subtract) Execute(x flamego.Context, a, b, c, d uint64) (uint64, uint64)

func (*Subtract) Format

func (i *Subtract) Format(x flamego.Context, a, b uint64) (uint64, uint64)

func (*Subtract) Load

func (i *Subtract) Load(x flamego.Context) (uint64, uint64, uint64, uint64)

func (*Subtract) Retire

func (i *Subtract) Retire(x flamego.Context) bool

func (*Subtract) Store

func (i *Subtract) Store(x flamego.Context, a, b uint64)

func (*Subtract) String

func (i *Subtract) String() string

type Uninterrupt

type Uninterrupt struct {
	AddressRegister flamego.Register
	// contains filtered or unexported fields
}

func NewUninterrupt

func NewUninterrupt(r flamego.Register) *Uninterrupt

func (*Uninterrupt) Execute

func (i *Uninterrupt) Execute(x flamego.Context, a, b, c, d uint64) (uint64, uint64)

func (*Uninterrupt) Format

func (i *Uninterrupt) Format(x flamego.Context, a, b uint64) (uint64, uint64)

func (*Uninterrupt) Load

func (*Uninterrupt) Retire

func (i *Uninterrupt) Retire(x flamego.Context) bool

func (*Uninterrupt) Store

func (i *Uninterrupt) Store(x flamego.Context, a, b uint64)

func (*Uninterrupt) String

func (i *Uninterrupt) String() string

type Unlock

type Unlock struct {
	// contains filtered or unexported fields
}

func NewUnlock

func NewUnlock() *Unlock

func (*Unlock) Execute

func (i *Unlock) Execute(x flamego.Context, a, b, c, d uint64) (uint64, uint64)

func (*Unlock) Format

func (i *Unlock) Format(x flamego.Context, a, b uint64) (uint64, uint64)

func (*Unlock) Load

func (i *Unlock) Load(x flamego.Context) (uint64, uint64, uint64, uint64)

func (*Unlock) Retire

func (i *Unlock) Retire(x flamego.Context) bool

func (*Unlock) Store

func (i *Unlock) Store(x flamego.Context, a, b uint64)

func (*Unlock) String

func (i *Unlock) String() string

type Xor

type Xor struct {
	Source1Register     flamego.Register
	Source2Register     flamego.Register
	DestinationRegister flamego.Register
}

func NewXor

func NewXor(s1, s2, d flamego.Register) *Xor

func (*Xor) Execute

func (i *Xor) Execute(x flamego.Context, a, b, c, d uint64) (uint64, uint64)

func (*Xor) Format

func (i *Xor) Format(x flamego.Context, a, b uint64) (uint64, uint64)

func (*Xor) Load

func (i *Xor) Load(x flamego.Context) (uint64, uint64, uint64, uint64)

func (*Xor) Retire

func (i *Xor) Retire(x flamego.Context) bool

func (*Xor) Store

func (i *Xor) Store(x flamego.Context, a, b uint64)

func (*Xor) String

func (i *Xor) String() string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL