Class: AArch64::Instructions::ADR
- Inherits:
-
Object
- Object
- AArch64::Instructions::ADR
- Defined in:
- lib/aarch64/instructions/adr.rb
Overview
ADR – A64 Form PC-relative address ADR <Xd>, <label>
Instance Method Summary collapse
- #encode ⇒ Object
-
#initialize(xd, label) ⇒ ADR
constructor
A new instance of ADR.
Constructor Details
#initialize(xd, label) ⇒ ADR
Returns a new instance of ADR.
7 8 9 10 |
# File 'lib/aarch64/instructions/adr.rb', line 7 def initialize xd, label @xd = xd @label = label end |
Instance Method Details
#encode ⇒ Object
12 13 14 15 |
# File 'lib/aarch64/instructions/adr.rb', line 12 def encode label = @label.to_i ADR(label, label >> 2, @xd.to_i) end |