Class: AArch64::Instructions::STR_imm_unsigned

Inherits:
Instruction
  • Object
show all
Defined in:
lib/aarch64/instructions/str_imm_unsigned.rb

Overview

STR (immediate) – A64 Store Register (immediate) STR <Wt>, [<Xn|SP>#<pimm>] STR <Xt>, [<Xn|SP>#<pimm>]

Instance Method Summary collapse

Constructor Details

#initialize(rt, rn, imm12, size) ⇒ STR_imm_unsigned

Returns a new instance of STR_imm_unsigned.



8
9
10
11
12
13
# File 'lib/aarch64/instructions/str_imm_unsigned.rb', line 8

def initialize rt, rn, imm12, size
  @rt    = check_mask(rt, 0x1f)
  @rn    = check_mask(rn, 0x1f)
  @imm12 = check_mask(imm12, 0xfff)
  @size  = check_mask(size, 0x03)
end

Instance Method Details

#encode(_) ⇒ Object



15
16
17
# File 'lib/aarch64/instructions/str_imm_unsigned.rb', line 15

def encode _
  STR_imm_gen(@size, @imm12, @rn, @rt)
end