source stringclasses 1
value | repo stringlengths 5 63 | repo_url stringlengths 24 82 | path stringlengths 5 167 | language stringclasses 1
value | license stringclasses 5
values | stars int64 10 51.4k | ref stringclasses 23
values | size_bytes int64 200 258k | text stringlengths 137 258k |
|---|---|---|---|---|---|---|---|---|---|
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/addg.rb | Ruby | apache-2.0 | 95 | main | 686 | module AArch64
module Instructions
# ADDG -- A64
# Add with Tag
# ADDG <Xd|SP>, <Xn|SP>, #<uimm6>, #<uimm4>
class ADDG < Instruction
def initialize xd, xn, imm6, imm4
@xd = check_mask(xd, 0x1f)
@xn = check_mask(xn, 0x1f)
@imm6 = check_mask(imm6, 0x3f)
@imm4 =... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/b_uncond.rb | Ruby | apache-2.0 | 95 | main | 430 | module AArch64
module Instructions
# B -- A64
# Branch
# B <label>
class B_uncond < Instruction
def initialize label
@label = label
end
def encode pos
B_uncond(check_mask(unwrap_label(@label, pos), 0x3ffffff))
end
private
def B_uncond imm26
... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/csinv.rb | Ruby | apache-2.0 | 95 | main | 795 | module AArch64
module Instructions
# CSINV -- A64
# Conditional Select Invert
# CSINV <Wd>, <Wn>, <Wm>, <cond>
# CSINV <Xd>, <Xn>, <Xm>, <cond>
class CSINV < Instruction
def initialize rd, rn, rm, cond, sf
@rd = check_mask(rd, 0x1f)
@rn = check_mask(rn, 0x1f)
@r... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/gmi.rb | Ruby | apache-2.0 | 95 | main | 561 | module AArch64
module Instructions
# GMI -- A64
# Tag Mask Insert
# GMI <Xd>, <Xn|SP>, <Xm>
class GMI < Instruction
def initialize rd, rn, rm
@rd = check_mask(rd, 0x1f)
@rn = check_mask(rn, 0x1f)
@rm = check_mask(rm, 0x1f)
end
def encode _
GMI(@rm, @... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/crc32c.rb | Ruby | apache-2.0 | 95 | main | 849 | module AArch64
module Instructions
# CRC32CB, CRC32CH, CRC32CW, CRC32CX -- A64
# CRC32C checksum
# CRC32CB <Wd>, <Wn>, <Wm>
# CRC32CH <Wd>, <Wn>, <Wm>
# CRC32CW <Wd>, <Wn>, <Wm>
# CRC32CX <Wd>, <Wn>, <Xm>
class CRC32C < Instruction
def initialize rd, rn, rm, sz, sf
@rd = ... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/setf.rb | Ruby | apache-2.0 | 95 | main | 530 | module AArch64
module Instructions
# SETF8, SETF16 -- A64
# Evaluation of 8 or 16 bit flag values
# SETF8 <Wn>
# SETF16 <Wn>
class SETF < Instruction
def initialize rn, sz
@rn = check_mask(rn, 0x1f)
@sz = check_mask(sz, 0x01)
end
def encode _
SETF(@sz, ... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/prfm_lit.rb | Ruby | apache-2.0 | 95 | main | 562 | module AArch64
module Instructions
# PRFM (literal) -- A64
# Prefetch Memory (literal)
# PRFM (<prfop>|#<imm5>), <label>
class PRFM_lit < Instruction
def initialize rt, label
@label = label
@rt = check_mask(rt, 0x1f)
end
def encode pos
PRFM_lit(check_mask... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/stllrb.rb | Ruby | apache-2.0 | 95 | main | 511 | module AArch64
module Instructions
# STLLRB -- A64
# Store LORelease Register Byte
# STLLRB <Wt>, [<Xn|SP>{,#0}]
class STLLRB < Instruction
def initialize rt, rn
@rt = check_mask(rt, 0x1f)
@rn = check_mask(rn, 0x1f)
end
def encode _
STLLRB(@rn, @rt)
en... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/hlt.rb | Ruby | apache-2.0 | 95 | main | 407 | module AArch64
module Instructions
# HLT -- A64
# Halt instruction
# HLT #<imm>
class HLT < Instruction
def initialize imm
@imm = check_mask(imm, 0xffff)
end
def encode _
HLT(@imm)
end
private
def HLT imm16
insn = 0b11010100_010_000000000... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/swpb.rb | Ruby | apache-2.0 | 95 | main | 844 | module AArch64
module Instructions
# SWPB, SWPAB, SWPALB, SWPLB -- A64
# Swap byte in memory
# SWPAB <Ws>, <Wt>, [<Xn|SP>]
# SWPALB <Ws>, <Wt>, [<Xn|SP>]
# SWPB <Ws>, <Wt>, [<Xn|SP>]
# SWPLB <Ws>, <Wt>, [<Xn|SP>]
class SWPB < Instruction
def initialize rs, rt, rn, a, r
@r... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/movk.rb | Ruby | apache-2.0 | 95 | main | 725 | module AArch64
module Instructions
# MOVK -- A64
# Move wide with keep
# MOVK <Wd>, #<imm>{, LSL #<shift>}
# MOVK <Xd>, #<imm>{, LSL #<shift>}
class MOVK < Instruction
def initialize reg, imm, shift, sf
@reg = check_mask(reg, 0x1f)
@imm = check_mask(imm, 0xffff)
... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/ldlar.rb | Ruby | apache-2.0 | 95 | main | 627 | module AArch64
module Instructions
# LDLAR -- A64
# Load LOAcquire Register
# LDLAR <Wt>, [<Xn|SP>{,#0}]
# LDLAR <Xt>, [<Xn|SP>{,#0}]
class LDLAR < Instruction
def initialize rt, rn, size
@rt = check_mask(rt, 0x1f)
@rn = check_mask(rn, 0x1f)
@size = check_mask(s... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/adc.rb | Ruby | apache-2.0 | 95 | main | 657 | module AArch64
module Instructions
# ADC -- A64
# Add with Carry
# ADC <Wd>, <Wn>, <Wm>
# ADC <Xd>, <Xn>, <Xm>
class ADC < Instruction
def initialize rd, rn, rm, sf
@rd = check_mask(rd, 0x1f)
@rn = check_mask(rn, 0x1f)
@rm = check_mask(rm, 0x1f)
@sf = check_... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/ldseth.rb | Ruby | apache-2.0 | 95 | main | 883 | module AArch64
module Instructions
# LDSETH, LDSETAH, LDSETALH, LDSETLH -- A64
# Atomic bit set on halfword in memory
# LDSETAH <Ws>, <Wt>, [<Xn|SP>]
# LDSETALH <Ws>, <Wt>, [<Xn|SP>]
# LDSETH <Ws>, <Wt>, [<Xn|SP>]
# LDSETLH <Ws>, <Wt>, [<Xn|SP>]
class LDSETH < Instruction
def ini... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/csel.rb | Ruby | apache-2.0 | 95 | main | 781 | module AArch64
module Instructions
# CSEL -- A64
# Conditional Select
# CSEL <Wd>, <Wn>, <Wm>, <cond>
# CSEL <Xd>, <Xn>, <Xm>, <cond>
class CSEL < Instruction
def initialize rd, rn, rm, cond, sf
@rd = check_mask(rd, 0x1f)
@rn = check_mask(rn, 0x1f)
@rm = check... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/sbcs.rb | Ruby | apache-2.0 | 95 | main | 683 | module AArch64
module Instructions
# SBCS -- A64
# Subtract with Carry, setting flags
# SBCS <Wd>, <Wn>, <Wm>
# SBCS <Xd>, <Xn>, <Xm>
class SBCS < Instruction
def initialize rd, rn, rm, sf
@rd = check_mask(rd, 0x1f)
@rn = check_mask(rn, 0x1f)
@rm = check_mask(rm, 0x... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/ld64b.rb | Ruby | apache-2.0 | 95 | main | 512 | module AArch64
module Instructions
# LD64B -- A64
# Single-copy Atomic 64-byte Load
# LD64B <Xt>, [<Xn|SP> {,#0}]
class LD64B < Instruction
def initialize rt, rn
@rt = check_mask(rt, 0x1f)
@rn = check_mask(rn, 0x1f)
end
def encode _
LD64B(@rn, @rt)
end... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/autdb.rb | Ruby | apache-2.0 | 95 | main | 608 | module AArch64
module Instructions
# AUTDB, AUTDZB -- A64
# Authenticate Data address, using key B
# AUTDB <Xd>, <Xn|SP>
# AUTDZB <Xd>
class AUTDB < Instruction
def initialize z, rd, rn
@z = check_mask(z, 0x01)
@rd = check_mask(rd, 0x1f)
@rn = check_mask(rn, 0x1f)
... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/cfinv.rb | Ruby | apache-2.0 | 95 | main | 220 | module AArch64
module Instructions
# CFINV -- A64
# Invert Carry Flag
# CFINV
class CFINV < Instruction
def encode _
0b1101010100_0_0_0_000_0100_0000_000_11111
end
end
end
end |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/strb_reg.rb | Ruby | apache-2.0 | 95 | main | 872 | module AArch64
module Instructions
# STRB (register) -- A64
# Store Register Byte (register)
# STRB <Wt>, [<Xn|SP>, (<Wm>|<Xm>), <extend> {<amount>}]
# STRB <Wt>, [<Xn|SP>, <Xm>{, LSL <amount>}]
class STRB_reg < Instruction
def initialize rt, rn, rm, option, s
@rt = check_mask(... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/adcs.rb | Ruby | apache-2.0 | 95 | main | 649 | module AArch64
module Instructions
# ADCS -- A64
# Add with Carry, setting flags
# ADCS <Wd>, <Wn>, <Wm>
class ADCS < Instruction
def initialize rd, rn, rm, sf
@rd = check_mask(rd, 0x1f)
@rn = check_mask(rn, 0x1f)
@rm = check_mask(rm, 0x1f)
@sf = check_mask(sf, 0... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/ldrh_reg.rb | Ruby | apache-2.0 | 95 | main | 827 | module AArch64
module Instructions
# LDRH (register) -- A64
# Load Register Halfword (register)
# LDRH <Wt>, [<Xn|SP>, (<Wm>|<Xm>){, <extend> {<amount>}}]
class LDRH_reg < Instruction
def initialize rt, rn, rm, s, option
@rt = check_mask(rt, 0x1f)
@rn = check_mask(rn, 0x... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/stzgm.rb | Ruby | apache-2.0 | 95 | main | 506 | module AArch64
module Instructions
# STZGM -- A64
# Store Tag and Zero Multiple
# STZGM <Xt>, [<Xn|SP>]
class STZGM < Instruction
def initialize rt, rn
@rt = check_mask(rt, 0x1f)
@rn = check_mask(rn, 0x1f)
end
def encode _
STZGM(@rn, @rt)
end
pr... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/eret.rb | Ruby | apache-2.0 | 95 | main | 216 | module AArch64
module Instructions
# ERET -- A64
# Exception Return
# ERET
class ERET < Instruction
def encode _
0b1101011_0_100_11111_0000_0_0_11111_00000
end
end
end
end |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/ldrb_unsigned.rb | Ruby | apache-2.0 | 95 | main | 638 | module AArch64
module Instructions
# LDRB (immediate) -- A64
# Load Register Byte (immediate)
# LDRB <Wt>, [<Xn|SP>{, #<pimm>}]
class LDRB_unsigned < Instruction
def initialize rt, rn, imm12
@rt = check_mask(rt, 0x1f)
@rn = check_mask(rn, 0x1f)
@imm12 = check_mask(... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/str_imm_unsigned.rb | Ruby | apache-2.0 | 95 | main | 770 | module AArch64
module Instructions
# STR (immediate) -- A64
# Store Register (immediate)
# STR <Wt>, [<Xn|SP>{, #<pimm>}]
# STR <Xt>, [<Xn|SP>{, #<pimm>}]
class STR_imm_unsigned < Instruction
def initialize rt, rn, imm12, size
@rt = check_mask(rt, 0x1f)
@rn = check_ma... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/ldtrsh.rb | Ruby | apache-2.0 | 95 | main | 751 | module AArch64
module Instructions
# LDTRSH -- A64
# Load Register Signed Halfword (unprivileged)
# LDTRSH <Wt>, [<Xn|SP>{, #<simm>}]
# LDTRSH <Xt>, [<Xn|SP>{, #<simm>}]
class LDTRSH < Instruction
def initialize rt, rn, imm9, opc
@rt = check_mask(rt, 0x1f)
@rn = check_m... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/clrex.rb | Ruby | apache-2.0 | 95 | main | 415 | module AArch64
module Instructions
# CLREX -- A64
# Clear Exclusive
# CLREX {#<imm>}
class CLREX < Instruction
def initialize imm
@imm = check_mask(imm, 0x0f)
end
def encode _
CLREX(@imm)
end
private
def CLREX crm
insn = 0b1101010100_0_00... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/cas.rb | Ruby | apache-2.0 | 95 | main | 1,102 | module AArch64
module Instructions
# CAS, CASA, CASAL, CASL -- A64
# Compare and Swap word or doubleword in memory
# CAS <Ws>, <Wt>, [<Xn|SP>{,#0}]
# CASA <Ws>, <Wt>, [<Xn|SP>{,#0}]
# CASAL <Ws>, <Wt>, [<Xn|SP>{,#0}]
# CASL <Ws>, <Wt>, [<Xn|SP>{,#0}]
# CAS <Xs>, <Xt>, [<Xn|SP>{,#0}]
... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/adds.rb | Ruby | apache-2.0 | 95 | main | 276 | module AArch64
module Instructions
module ADDS
autoload :ADDSUB_ext, "aarch64/instructions/adds/addsub_ext"
autoload :ADDSUB_imm, "aarch64/instructions/adds/addsub_imm"
autoload :ADDSUB_shift, "aarch64/instructions/adds/addsub_shift"
end
end
end |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/cash.rb | Ruby | apache-2.0 | 95 | main | 881 | module AArch64
module Instructions
# CASH, CASAH, CASALH, CASLH -- A64
# Compare and Swap halfword in memory
# CASAH <Ws>, <Wt>, [<Xn|SP>{,#0}]
# CASALH <Ws>, <Wt>, [<Xn|SP>{,#0}]
# CASH <Ws>, <Wt>, [<Xn|SP>{,#0}]
# CASLH <Ws>, <Wt>, [<Xn|SP>{,#0}]
class CASH < Instruction
def in... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/prfm_imm.rb | Ruby | apache-2.0 | 95 | main | 642 | module AArch64
module Instructions
# PRFM (immediate) -- A64
# Prefetch Memory (immediate)
# PRFM (<prfop>|#<imm5>), [<Xn|SP>{, #<pimm>}]
class PRFM_imm < Instruction
def initialize rt, rn, imm12
@rt = check_mask(rt, 0x1f)
@rn = check_mask(rn, 0x1f)
@imm12 = check_... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/csinc.rb | Ruby | apache-2.0 | 95 | main | 798 | module AArch64
module Instructions
# CSINC -- A64
# Conditional Select Increment
# CSINC <Wd>, <Wn>, <Wm>, <cond>
# CSINC <Xd>, <Xn>, <Xm>, <cond>
class CSINC < Instruction
def initialize rd, rn, rm, cond, sf
@rd = check_mask(rd, 0x1f)
@rn = check_mask(rn, 0x1f)
... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/ldaddh.rb | Ruby | apache-2.0 | 95 | main | 879 | module AArch64
module Instructions
# LDADDH, LDADDAH, LDADDALH, LDADDLH -- A64
# Atomic add on halfword in memory
# LDADDAH <Ws>, <Wt>, [<Xn|SP>]
# LDADDALH <Ws>, <Wt>, [<Xn|SP>]
# LDADDH <Ws>, <Wt>, [<Xn|SP>]
# LDADDLH <Ws>, <Wt>, [<Xn|SP>]
class LDADDH < Instruction
def initial... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/pacia2.rb | Ruby | apache-2.0 | 95 | main | 602 | module AArch64
module Instructions
# PACIA, PACIA1716, PACIASP, PACIAZ, PACIZA -- A64
# Pointer Authentication Code for Instruction address, using key A
# PACIA1716
# PACIASP
# PACIAZ
class PACIA2 < Instruction
def initialize crm, op2
@crm = check_mask(crm, 0x0f)
@op2 = c... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/clz_int.rb | Ruby | apache-2.0 | 95 | main | 586 | module AArch64
module Instructions
# CLZ -- A64
# Count Leading Zeros
# CLZ <Wd>, <Wn>
# CLZ <Xd>, <Xn>
class CLZ_int < Instruction
def initialize rd, rn, sf
@rd = check_mask(rd, 0x1f)
@rn = check_mask(rn, 0x1f)
@sf = check_mask(sf, 0x01)
end
def encode... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/ldg.rb | Ruby | apache-2.0 | 95 | main | 585 | module AArch64
module Instructions
# LDG -- A64
# Load Allocation Tag
# LDG <Xt>, [<Xn|SP>{, #<simm>}]
class LDG < Instruction
def initialize xt, xn, imm9
@xt = check_mask(xt, 0x1f)
@xn = check_mask(xn, 0x1f)
@imm9 = check_mask(imm9, 0x1ff)
end
def encod... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/subps.rb | Ruby | apache-2.0 | 95 | main | 590 | module AArch64
module Instructions
# SUBPS -- A64
# Subtract Pointer, setting Flags
# SUBPS <Xd>, <Xn|SP>, <Xm|SP>
class SUBPS < Instruction
def initialize xd, xn, xm
@xd = check_mask(xd, 0x1f)
@xn = check_mask(xn, 0x1f)
@xm = check_mask(xm, 0x1f)
end
def en... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/ldrsw_reg.rb | Ruby | apache-2.0 | 95 | main | 835 | module AArch64
module Instructions
# LDRSW (register) -- A64
# Load Register Signed Word (register)
# LDRSW <Xt>, [<Xn|SP>, (<Wm>|<Xm>){, <extend> {<amount>}}]
class LDRSW_reg < Instruction
def initialize rt, rn, rm, s, option
@rt = check_mask(rt, 0x1f)
@rn = check_mask(... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/cbz.rb | Ruby | apache-2.0 | 95 | main | 624 | module AArch64
module Instructions
# CBZ -- A64
# Compare and Branch on Zero
# CBZ <Wt>, <label>
# CBZ <Xt>, <label>
class CBZ < Instruction
def initialize rt, label, sf
@rt = check_mask(rt, 0x1f)
@label = label
@sf = check_mask(sf, 0x1)
end
def e... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/st64b.rb | Ruby | apache-2.0 | 95 | main | 528 | module AArch64
module Instructions
# ST64B -- A64
# Single-copy Atomic 64-byte Store without Return
# ST64B <Xt>, [<Xn|SP> {,#0}]
class ST64B < Instruction
def initialize rt, rn
@rt = check_mask(rt, 0x1f)
@rn = check_mask(rn, 0x1f)
end
def encode _
ST64B(@rn... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/umulh.rb | Ruby | apache-2.0 | 95 | main | 572 | module AArch64
module Instructions
# UMULH -- A64
# Unsigned Multiply High
# UMULH <Xd>, <Xn>, <Xm>
class UMULH < Instruction
def initialize rd, rn, rm
@rd = check_mask(rd, 0x1f)
@rn = check_mask(rn, 0x1f)
@rm = check_mask(rm, 0x1f)
end
def encode _
... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/stzg.rb | Ruby | apache-2.0 | 95 | main | 767 | module AArch64
module Instructions
# STZG -- A64
# Store Allocation Tag, Zeroing
# STZG <Xt|SP>, [<Xn|SP>], #<simm>
# STZG <Xt|SP>, [<Xn|SP>, #<simm>]!
# STZG <Xt|SP>, [<Xn|SP>{, #<simm>}]
class STZG < Instruction
def initialize xt, xn, imm9, opt
@xt = check_mask(xt, 0x1f)
... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/bc_cond.rb | Ruby | apache-2.0 | 95 | main | 552 | module AArch64
module Instructions
# BC.cond -- A64
# Branch Consistent conditionally
# BC.<cond> <label>
class BC_cond < Instruction
def initialize cond, label
@cond = check_mask(cond, 0xf)
@label = label
end
def encode pos
BC_cond(check_mask(unwrap_label(... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/ldrsh_unsigned.rb | Ruby | apache-2.0 | 95 | main | 789 | module AArch64
module Instructions
# LDRSH (immediate) -- A64
# Load Register Signed Halfword (immediate)
# LDRSH <Wt>, [<Xn|SP>{, #<pimm>}]
# LDRSH <Xt>, [<Xn|SP>{, #<pimm>}]
class LDRSH_unsigned < Instruction
def initialize rt, rn, imm12, opc
@rt = check_mask(rt, 0x1f)
... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/ldxp.rb | Ruby | apache-2.0 | 95 | main | 717 | module AArch64
module Instructions
# LDXP -- A64
# Load Exclusive Pair of Registers
# LDXP <Wt1>, <Wt2>, [<Xn|SP>{,#0}]
# LDXP <Xt1>, <Xt2>, [<Xn|SP>{,#0}]
class LDXP < Instruction
def initialize rt, rt2, rn, sz
@rt = check_mask(rt, 0x1f)
@rt2 = check_mask(rt2, 0x1f)
... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/eon.rb | Ruby | apache-2.0 | 95 | main | 942 | module AArch64
module Instructions
# EON (shifted register) -- A64
# Bitwise Exclusive OR NOT (shifted register)
# EON <Wd>, <Wn>, <Wm>{, <shift> #<amount>}
# EON <Xd>, <Xn>, <Xm>{, <shift> #<amount>}
class EON < Instruction
def initialize rd, rn, rm, shift, imm, sf
@rd = check_... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/ereta.rb | Ruby | apache-2.0 | 95 | main | 448 | module AArch64
module Instructions
# ERETAA, ERETAB -- A64
# Exception Return, with pointer authentication
# ERETAA
# ERETAB
class ERETA < Instruction
def initialize m
@m = check_mask(m, 0x01)
end
def encode _
ERETA(@m)
end
private
def ERETA m... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/bti.rb | Ruby | apache-2.0 | 95 | main | 439 | module AArch64
module Instructions
# BTI -- A64
# Branch Target Identification
# BTI {<targets>}
class BTI < Instruction
def initialize target
@target = check_mask(target, 0x03)
end
def encode _
BTI(@target)
end
private
def BTI target
ins... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/rorv.rb | Ruby | apache-2.0 | 95 | main | 671 | module AArch64
module Instructions
# RORV -- A64
# Rotate Right Variable
# RORV <Wd>, <Wn>, <Wm>
# RORV <Xd>, <Xn>, <Xm>
class RORV < Instruction
def initialize rd, rn, rm, sf
@rd = check_mask(rd, 0x1f)
@rn = check_mask(rn, 0x1f)
@rm = check_mask(rm, 0x1f)
@... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/ldnp_gen.rb | Ruby | apache-2.0 | 95 | main | 844 | module AArch64
module Instructions
# LDNP -- A64
# Load Pair of Registers, with non-temporal hint
# LDNP <Wt1>, <Wt2>, [<Xn|SP>{, #<imm>}]
# LDNP <Xt1>, <Xt2>, [<Xn|SP>{, #<imm>}]
class LDNP_gen < Instruction
def initialize rt1, rt2, rn, imm, opc
@rt1 = check_mask(rt1, 0x1f)
... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/stllrh.rb | Ruby | apache-2.0 | 95 | main | 515 | module AArch64
module Instructions
# STLLRH -- A64
# Store LORelease Register Halfword
# STLLRH <Wt>, [<Xn|SP>{,#0}]
class STLLRH < Instruction
def initialize rt, rn
@rt = check_mask(rt, 0x1f)
@rn = check_mask(rn, 0x1f)
end
def encode _
STLLRH(@rn, @rt)
... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/swph.rb | Ruby | apache-2.0 | 95 | main | 848 | module AArch64
module Instructions
# SWPH, SWPAH, SWPALH, SWPLH -- A64
# Swap halfword in memory
# SWPAH <Ws>, <Wt>, [<Xn|SP>]
# SWPALH <Ws>, <Wt>, [<Xn|SP>]
# SWPH <Ws>, <Wt>, [<Xn|SP>]
# SWPLH <Ws>, <Wt>, [<Xn|SP>]
class SWPH < Instruction
def initialize rs, rt, rn, a, r
... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/ldrb_imm.rb | Ruby | apache-2.0 | 95 | main | 808 | module AArch64
module Instructions
# LDRB (immediate) -- A64
# Load Register Byte (immediate)
# LDRB <Wt>, [<Xn|SP>], #<simm>
# LDRB <Wt>, [<Xn|SP>, #<simm>]!
# LDRB <Wt>, [<Xn|SP>{, #<pimm>}]
class LDRB_imm < Instruction
def initialize rt, rn, imm9, option
@rt = check_mas... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/strh_imm.rb | Ruby | apache-2.0 | 95 | main | 790 | module AArch64
module Instructions
# STRH (immediate) -- A64
# Store Register Halfword (immediate)
# STRH <Wt>, [<Xn|SP>], #<simm>
# STRH <Wt>, [<Xn|SP>, #<simm>]!
# STRH <Wt>, [<Xn|SP>{, #<pimm>}]
class STRH_imm < Instruction
def initialize rt, rn, imm9, opt
@rt = check_mas... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/autib.rb | Ruby | apache-2.0 | 95 | main | 686 | module AArch64
module Instructions
# AUTIB, AUTIB1716, AUTIBSP, AUTIBZ, AUTIZB -- A64
# Authenticate Instruction address, using key B
# AUTIB <Xd>, <Xn|SP>
# AUTIZB <Xd>
# AUTIB1716
# AUTIBSP
# AUTIBZ
class AUTIB < Instruction
def initialize z, rd, rn
@z = check_mask(z... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/ldr_imm_gen.rb | Ruby | apache-2.0 | 95 | main | 914 | module AArch64
module Instructions
# LDR (immediate) -- A64
# Load Register (immediate)
# LDR <Wt>, [<Xn|SP>], #<simm>
# LDR <Xt>, [<Xn|SP>], #<simm>
# LDR <Wt>, [<Xn|SP>, #<simm>]!
# LDR <Xt>, [<Xn|SP>, #<simm>]!
class LDR_imm_gen < Instruction
def initialize rt, rn, imm9, size,... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/ldumin.rb | Ruby | apache-2.0 | 95 | main | 1,149 | module AArch64
module Instructions
# LDUMIN, LDUMINA, LDUMINAL, LDUMINL -- A64
# Atomic unsigned minimum on word or doubleword in memory
# LDUMIN <Ws>, <Wt>, [<Xn|SP>]
# LDUMINA <Ws>, <Wt>, [<Xn|SP>]
# LDUMINAL <Ws>, <Wt>, [<Xn|SP>]
# LDUMINL <Ws>, <Wt>, [<Xn|SP>]
# LDUMIN <Xs>, <Xt>,... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/tbnz.rb | Ruby | apache-2.0 | 95 | main | 701 | module AArch64
module Instructions
# TBNZ -- A64
# Test bit and Branch if Nonzero
# TBNZ <R><t>, #<imm>, <label>
class TBNZ < Instruction
def initialize rt, imm, label, sf
@rt = check_mask(rt, 0x1f)
@imm = check_mask(imm, 0x1f)
@label = label
@sf = check_... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/sbc.rb | Ruby | apache-2.0 | 95 | main | 662 | module AArch64
module Instructions
# SBC -- A64
# Subtract with Carry
# SBC <Wd>, <Wn>, <Wm>
# SBC <Xd>, <Xn>, <Xm>
class SBC < Instruction
def initialize rd, rn, rm, sf
@rd = check_mask(rd, 0x1f)
@rn = check_mask(rn, 0x1f)
@rm = check_mask(rm, 0x1f)
@sf = c... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/ldsmaxb.rb | Ruby | apache-2.0 | 95 | main | 897 | module AArch64
module Instructions
# LDSMAXB, LDSMAXAB, LDSMAXALB, LDSMAXLB -- A64
# Atomic signed maximum on byte in memory
# LDSMAXAB <Ws>, <Wt>, [<Xn|SP>]
# LDSMAXALB <Ws>, <Wt>, [<Xn|SP>]
# LDSMAXB <Ws>, <Wt>, [<Xn|SP>]
# LDSMAXLB <Ws>, <Wt>, [<Xn|SP>]
class LDSMAXB < Instruction
... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/stlrh.rb | Ruby | apache-2.0 | 95 | main | 508 | module AArch64
module Instructions
# STLRH -- A64
# Store-Release Register Halfword
# STLRH <Wt>, [<Xn|SP>{,#0}]
class STLRH < Instruction
def initialize rt, rn
@rt = check_mask(rt, 0x1f)
@rn = check_mask(rn, 0x1f)
end
def encode _
STLRH(@rn, @rt)
end
... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/umsubl.rb | Ruby | apache-2.0 | 95 | main | 669 | module AArch64
module Instructions
# UMSUBL -- A64
# Unsigned Multiply-Subtract Long
# UMSUBL <Xd>, <Wn>, <Wm>, <Xa>
class UMSUBL < Instruction
def initialize xd, wn, wm, xa
@xd = check_mask(xd, 0x1f)
@wn = check_mask(wn, 0x1f)
@wm = check_mask(wm, 0x1f)
@xa = ch... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/ldursb.rb | Ruby | apache-2.0 | 95 | main | 743 | module AArch64
module Instructions
# LDURSB -- A64
# Load Register Signed Byte (unscaled)
# LDURSB <Wt>, [<Xn|SP>{, #<simm>}]
# LDURSB <Xt>, [<Xn|SP>{, #<simm>}]
class LDURSB < Instruction
def initialize rt, rn, imm9, opc
@rt = check_mask(rt, 0x1f)
@rn = check_mask(rn, ... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/lslv.rb | Ruby | apache-2.0 | 95 | main | 677 | module AArch64
module Instructions
# LSLV -- A64
# Logical Shift Left Variable
# LSLV <Wd>, <Wn>, <Wm>
# LSLV <Xd>, <Xn>, <Xm>
class LSLV < Instruction
def initialize rd, rn, rm, sf
@rd = check_mask(rd, 0x1f)
@rn = check_mask(rn, 0x1f)
@rm = check_mask(rm, 0x1f)
... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/tbz.rb | Ruby | apache-2.0 | 95 | main | 693 | module AArch64
module Instructions
# TBZ -- A64
# Test bit and Branch if Zero
# TBZ <R><t>, #<imm>, <label>
class TBZ < Instruction
def initialize rt, imm, label, sf
@rt = check_mask(rt, 0x1f)
@imm = check_mask(imm, 0x1f)
@label = label
@sf = check_mask(s... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/ldtrsw.rb | Ruby | apache-2.0 | 95 | main | 622 | module AArch64
module Instructions
# LDTRSW -- A64
# Load Register Signed Word (unprivileged)
# LDTRSW <Xt>, [<Xn|SP>{, #<simm>}]
class LDTRSW < Instruction
def initialize rt, rn, imm9
@rt = check_mask(rt, 0x1f)
@rn = check_mask(rn, 0x1f)
@imm9 = check_mask(imm9, 0x1... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/dsb.rb | Ruby | apache-2.0 | 95 | main | 456 | module AArch64
module Instructions
# DSB -- A64
# Data Synchronization Barrier
# DSB <option>|#<imm>
# DSB <option>nXS|#<imm>
class DSB < Instruction
def initialize imm
@imm = check_mask(imm, 0x0f)
end
def encode _
DSB(@imm)
end
private
def ... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/ldaxp.rb | Ruby | apache-2.0 | 95 | main | 734 | module AArch64
module Instructions
# LDAXP -- A64
# Load-Acquire Exclusive Pair of Registers
# LDAXP <Wt1>, <Wt2>, [<Xn|SP>{,#0}]
# LDAXP <Xt1>, <Xt2>, [<Xn|SP>{,#0}]
class LDAXP < Instruction
def initialize rt1, rt2, rn, sf
@rt1 = check_mask(rt1, 0x1f)
@rt2 = check_mask(rt... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/csdb.rb | Ruby | apache-2.0 | 95 | main | 238 | module AArch64
module Instructions
# CSDB -- A64
# Consumption of Speculative Data Barrier
# CSDB
class CSDB < Instruction
def encode _
0b1101010100_0_00_011_0010_0010_100_11111
end
end
end
end |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/ldsminh.rb | Ruby | apache-2.0 | 95 | main | 901 | module AArch64
module Instructions
# LDSMINH, LDSMINAH, LDSMINALH, LDSMINLH -- A64
# Atomic signed minimum on halfword in memory
# LDSMINAH <Ws>, <Wt>, [<Xn|SP>]
# LDSMINALH <Ws>, <Wt>, [<Xn|SP>]
# LDSMINH <Ws>, <Wt>, [<Xn|SP>]
# LDSMINLH <Ws>, <Wt>, [<Xn|SP>]
class LDSMINH < Instructi... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/blra.rb | Ruby | apache-2.0 | 95 | main | 756 | module AArch64
module Instructions
# BLRAA, BLRAAZ, BLRAB, BLRABZ -- A64
# Branch with Link to Register, with pointer authentication
# BLRAAZ <Xn>
# BLRAA <Xn>, <Xm|SP>
# BLRABZ <Xn>
# BLRAB <Xn>, <Xm|SP>
class BLRA < Instruction
def initialize rn, rm, z, m
@rn = check_ma... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/strh_imm_unsigned.rb | Ruby | apache-2.0 | 95 | main | 666 | module AArch64
module Instructions
# STRH (immediate) -- A64
# Store Register Halfword (immediate)
# STRH <Wt>, [<Xn|SP>{, #<pimm>}]
class STRH_imm_unsigned < Instruction
def initialize rt, rn, imm12
@rt = check_mask(rt, 0x1f)
@rn = check_mask(rn, 0x1f)
@imm12 = ch... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/bl.rb | Ruby | apache-2.0 | 95 | main | 424 | module AArch64
module Instructions
# BL -- A64
# Branch with Link
# BL <label>
class BL < Instruction
def initialize label
@label = label
end
def encode pos
BL(check_mask(unwrap_label(@label, pos), 0x3ffffff))
end
private
def BL imm26
ins... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/ccmn_imm.rb | Ruby | apache-2.0 | 95 | main | 856 | module AArch64
module Instructions
# CCMN (immediate) -- A64
# Conditional Compare Negative (immediate)
# CCMN <Wn>, #<imm>, #<nzcv>, <cond>
# CCMN <Xn>, #<imm>, #<nzcv>, <cond>
class CCMN_imm < Instruction
def initialize rn, imm, nzcv, cond, sf
@rn = check_mask(rn, 0x1f)
... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/ldrsw_unsigned.rb | Ruby | apache-2.0 | 95 | main | 737 | module AArch64
module Instructions
# LDRSW (immediate) -- A64
# Load Register Signed Word (immediate)
# LDRSW <Xt>, [<Xn|SP>], #<simm>
# LDRSW <Xt>, [<Xn|SP>, #<simm>]!
# LDRSW <Xt>, [<Xn|SP>{, #<pimm>}]
class LDRSW_unsigned < Instruction
def initialize rt, rn, imm12
@rt = ... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/ldaddb.rb | Ruby | apache-2.0 | 95 | main | 875 | module AArch64
module Instructions
# LDADDB, LDADDAB, LDADDALB, LDADDLB -- A64
# Atomic add on byte in memory
# LDADDAB <Ws>, <Wt>, [<Xn|SP>]
# LDADDALB <Ws>, <Wt>, [<Xn|SP>]
# LDADDB <Ws>, <Wt>, [<Xn|SP>]
# LDADDLB <Ws>, <Wt>, [<Xn|SP>]
class LDADDB < Instruction
def initialize ... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/casb.rb | Ruby | apache-2.0 | 95 | main | 877 | module AArch64
module Instructions
# CASB, CASAB, CASALB, CASLB -- A64
# Compare and Swap byte in memory
# CASAB <Ws>, <Wt>, [<Xn|SP>{,#0}]
# CASALB <Ws>, <Wt>, [<Xn|SP>{,#0}]
# CASB <Ws>, <Wt>, [<Xn|SP>{,#0}]
# CASLB <Ws>, <Wt>, [<Xn|SP>{,#0}]
class CASB < Instruction
def initia... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/ldaxr.rb | Ruby | apache-2.0 | 95 | main | 635 | module AArch64
module Instructions
# LDAXR -- A64
# Load-Acquire Exclusive Register
# LDAXR <Wt>, [<Xn|SP>{,#0}]
# LDAXR <Xt>, [<Xn|SP>{,#0}]
class LDAXR < Instruction
def initialize rt, rn, size
@rt = check_mask(rt, 0x1f)
@rn = check_mask(rn, 0x1f)
@size = chec... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/ccmp_reg.rb | Ruby | apache-2.0 | 95 | main | 834 | module AArch64
module Instructions
# CCMP (register) -- A64
# Conditional Compare (register)
# CCMP <Wn>, <Wm>, #<nzcv>, <cond>
# CCMP <Xn>, <Xm>, #<nzcv>, <cond>
class CCMP_reg < Instruction
def initialize rn, rm, nzcv, cond, sf
@rn = check_mask(rn, 0x1f)
@rm = check_m... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/axflag.rb | Ruby | apache-2.0 | 95 | main | 271 | module AArch64
module Instructions
# AXFLAG -- A64
# Convert floating-point condition flags from Arm to external format
# AXFLAG
class AXFLAG < Instruction
def encode _
0b1101010100_0_00_000_0100_0000_010_11111
end
end
end
end |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/stz2g.rb | Ruby | apache-2.0 | 95 | main | 775 | module AArch64
module Instructions
# STZ2G -- A64
# Store Allocation Tags, Zeroing
# STZ2G <Xt|SP>, [<Xn|SP>], #<simm>
# STZ2G <Xt|SP>, [<Xn|SP>, #<simm>]!
# STZ2G <Xt|SP>, [<Xn|SP>{, #<simm>}]
class STZ2G < Instruction
def initialize xt, xn, imm9, opt
@xt = check_mask(xt, 0... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/autia.rb | Ruby | apache-2.0 | 95 | main | 686 | module AArch64
module Instructions
# AUTIA, AUTIA1716, AUTIASP, AUTIAZ, AUTIZA -- A64
# Authenticate Instruction address, using key A
# AUTIA <Xd>, <Xn|SP>
# AUTIZA <Xd>
# AUTIA1716
# AUTIASP
# AUTIAZ
class AUTIA < Instruction
def initialize z, rd, rn
@z = check_mask(z... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/stlr.rb | Ruby | apache-2.0 | 95 | main | 620 | module AArch64
module Instructions
# STLR -- A64
# Store-Release Register
# STLR <Wt>, [<Xn|SP>{,#0}]
# STLR <Xt>, [<Xn|SP>{,#0}]
class STLR < Instruction
def initialize rt, rn, size
@rt = check_mask(rt, 0x1f)
@rn = check_mask(rn, 0x1f)
@size = check_mask(size, ... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/ldrsh_imm.rb | Ruby | apache-2.0 | 95 | main | 1,029 | module AArch64
module Instructions
# LDRSH (immediate) -- A64
# Load Register Signed Halfword (immediate)
# LDRSH <Wt>, [<Xn|SP>], #<simm>
# LDRSH <Xt>, [<Xn|SP>], #<simm>
# LDRSH <Wt>, [<Xn|SP>, #<simm>]!
# LDRSH <Xt>, [<Xn|SP>, #<simm>]!
# LDRSH <Wt>, [<Xn|SP>{, #<pimm>}]
# LDRS... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/xpaclri.rb | Ruby | apache-2.0 | 95 | main | 234 | module AArch64
module Instructions
# XPACLRI -- A64
# Strip Pointer Authentication Code
# XPACLRI
class XPACLRI < Instruction
def encode _
0b11010101000000110010000011111111
end
end
end
end |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/stllr.rb | Ruby | apache-2.0 | 95 | main | 628 | module AArch64
module Instructions
# STLLR -- A64
# Store LORelease Register
# STLLR <Wt>, [<Xn|SP>{,#0}]
# STLLR <Xt>, [<Xn|SP>{,#0}]
class STLLR < Instruction
def initialize rt, rn, size
@rt = check_mask(rt, 0x1f)
@rn = check_mask(rn, 0x1f)
@size = check_mask(... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/sev.rb | Ruby | apache-2.0 | 95 | main | 206 | module AArch64
module Instructions
# SEV -- A64
# Send Event
# SEV
class SEV < Instruction
def encode _
0b1101010100_0_00_011_0010_0000_100_11111
end
end
end
end |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/ldsetb.rb | Ruby | apache-2.0 | 95 | main | 879 | module AArch64
module Instructions
# LDSETB, LDSETAB, LDSETALB, LDSETLB -- A64
# Atomic bit set on byte in memory
# LDSETAB <Ws>, <Wt>, [<Xn|SP>]
# LDSETALB <Ws>, <Wt>, [<Xn|SP>]
# LDSETB <Ws>, <Wt>, [<Xn|SP>]
# LDSETLB <Ws>, <Wt>, [<Xn|SP>]
class LDSETB < Instruction
def initial... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/wfi.rb | Ruby | apache-2.0 | 95 | main | 214 | module AArch64
module Instructions
# WFI -- A64
# Wait For Interrupt
# WFI
class WFI < Instruction
def encode _
0b1101010100_0_00_011_0010_0000_011_11111
end
end
end
end |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/ldtrsb.rb | Ruby | apache-2.0 | 95 | main | 747 | module AArch64
module Instructions
# LDTRSB -- A64
# Load Register Signed Byte (unprivileged)
# LDTRSB <Wt>, [<Xn|SP>{, #<simm>}]
# LDTRSB <Xt>, [<Xn|SP>{, #<simm>}]
class LDTRSB < Instruction
def initialize rt, rn, imm9, opc
@rt = check_mask(rt, 0x1f)
@rn = check_mask(... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/stur_gen.rb | Ruby | apache-2.0 | 95 | main | 737 | module AArch64
module Instructions
# STUR -- A64
# Store Register (unscaled)
# STUR <Wt>, [<Xn|SP>{, #<simm>}]
# STUR <Xt>, [<Xn|SP>{, #<simm>}]
class STUR_gen < Instruction
def initialize rt, rn, imm9, size
@rt = check_mask(rt, 0x1f)
@rn = check_mask(rn, 0x1f)
... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/ldr_reg_gen.rb | Ruby | apache-2.0 | 95 | main | 979 | module AArch64
module Instructions
# LDR (register) -- A64
# Load Register (register)
# LDR <Wt>, [<Xn|SP>, (<Wm>|<Xm>){, <extend> {<amount>}}]
# LDR <Xt>, [<Xn|SP>, (<Wm>|<Xm>){, <extend> {<amount>}}]
class LDR_reg_gen < Instruction
def initialize rt, rn, rm, size, option, s
@rt ... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/ldursw.rb | Ruby | apache-2.0 | 95 | main | 618 | module AArch64
module Instructions
# LDURSW -- A64
# Load Register Signed Word (unscaled)
# LDURSW <Xt>, [<Xn|SP>{, #<simm>}]
class LDURSW < Instruction
def initialize rt, rn, imm9
@rt = check_mask(rt, 0x1f)
@rn = check_mask(rn, 0x1f)
@imm9 = check_mask(imm9, 0x1ff)
... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/ldadd.rb | Ruby | apache-2.0 | 95 | main | 1,121 | module AArch64
module Instructions
# LDADD, LDADDA, LDADDAL, LDADDL -- A64
# Atomic add on word or doubleword in memory
# LDADD <Ws>, <Wt>, [<Xn|SP>]
# LDADDA <Ws>, <Wt>, [<Xn|SP>]
# LDADDAL <Ws>, <Wt>, [<Xn|SP>]
# LDADDL <Ws>, <Wt>, [<Xn|SP>]
# LDADD <Xs>, <Xt>, [<Xn|SP>]
# LDADD... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/adrp.rb | Ruby | apache-2.0 | 95 | main | 617 | module AArch64
module Instructions
# ADRP -- A64
# Form PC-relative address to 4KB page
# ADRP <Xd>, <label>
class ADRP < Instruction
def initialize xd, label
@xd = check_mask(xd, 0x1f)
@label = label
end
def encode _
label = unwrap_label(@label, 0) / 409... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/st64bv0.rb | Ruby | apache-2.0 | 95 | main | 616 | module AArch64
module Instructions
# ST64BV0 -- A64
# Single-copy Atomic 64-byte EL0 Store with Return
# ST64BV0 <Xs>, <Xt>, [<Xn|SP>]
class ST64BV0 < Instruction
def initialize rs, rt, rn
@rs = check_mask(rs, 0x1f)
@rt = check_mask(rt, 0x1f)
@rn = check_mask(rn, 0x1f)
... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/isb.rb | Ruby | apache-2.0 | 95 | main | 434 | module AArch64
module Instructions
# ISB -- A64
# Instruction Synchronization Barrier
# ISB {<option>|#<imm>}
class ISB < Instruction
def initialize imm
@imm = check_mask(imm, 0x0f)
end
def encode _
ISB @imm
end
private
def ISB crm
insn =... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/ldaprh.rb | Ruby | apache-2.0 | 95 | main | 521 | module AArch64
module Instructions
# LDAPRH -- A64
# Load-Acquire RCpc Register Halfword
# LDAPRH <Wt>, [<Xn|SP> {,#0}]
class LDAPRH < Instruction
def initialize rt, rn
@rt = check_mask(rt, 0x1f)
@rn = check_mask(rn, 0x1f)
end
def encode _
LDAPRH(@rn, @rt)
... |
github | tenderlove/aarch64 | https://github.com/tenderlove/aarch64 | lib/aarch64/instructions/pacda.rb | Ruby | apache-2.0 | 95 | main | 627 | module AArch64
module Instructions
# PACDA, PACDZA -- A64
# Pointer Authentication Code for Data address, using key A
# PACDA <Xd>, <Xn|SP>
# PACDZA <Xd>
class PACDA < Instruction
def initialize rd, rn, z
@rd = check_mask(rd, 0x1f)
@rn = check_mask(rn, 0x1f)
@z = c... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.