Class: AArch64::Instructions::BFM

Inherits:
Instruction show all
Defined in:
lib/aarch64/instructions/bfm.rb

Overview

BFM – A64 Bitfield Move BFM <Wd>, <Wn>, #<immr>, #<imms> BFM <Xd>, <Xn>, #<immr>, #<imms>

Instance Method Summary collapse

Constructor Details

#initialize(d, n, immr, imms, sf) ⇒ BFM

Returns a new instance of BFM.



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

def initialize d, n, immr, imms, sf
  @d    = check_mask(d, 0x1f)
  @n    = check_mask(n, 0x1f)
  @immr = check_mask(immr, 0x3f)
  @imms = check_mask(imms, 0x3f)
  @sf   = check_mask(sf, 0x01)
end

Instance Method Details

#encode(_) ⇒ Object



16
17
18
# File 'lib/aarch64/instructions/bfm.rb', line 16

def encode _
  BFM(@sf, @sf, @immr, @imms, @n, @d)
end