Class: SeccompTools::Instruction::ST
- Defined in:
- lib/seccomp-tools/instruction/st.rb
Overview
Instruction st.
Direct Known Subclasses
Constant Summary
Constants included from Const::BPF
Const::BPF::ACTION, Const::BPF::COMMAND, Const::BPF::JMP, Const::BPF::MISCOP, Const::BPF::MODE, Const::BPF::OP, Const::BPF::PR_SET_SECCOMP, Const::BPF::SECCOMP_MODE_FILTER, Const::BPF::SECCOMP_RET_ACTION_FULL, Const::BPF::SECCOMP_RET_DATA, Const::BPF::SECCOMP_SET_MODE_FILTER, Const::BPF::SIZEOF_SECCOMP_DATA, Const::BPF::SRC
Instance Method Summary collapse
- #branch(context) ⇒ Array<(Integer, Context)>
-
#decompile ⇒ Object
Decompile instruction.
-
#symbolize ⇒ [:st, (:a, :x), Integer]
See Base#symbolize.
Methods inherited from LD
Methods inherited from Base
Constructor Details
This class inherits a constructor from SeccompTools::Instruction::Base
Instance Method Details
#branch(context) ⇒ Array<(Integer, Context)>
21 22 23 24 25 |
# File 'lib/seccomp-tools/instruction/st.rb', line 21 def branch(context) ctx = context.dup ctx.store(k, reg) [[line + 1, ctx]] end |
#decompile ⇒ Object
Decompile instruction.
10 11 12 |
# File 'lib/seccomp-tools/instruction/st.rb', line 10 def decompile "mem[#{k}] = #{reg}" end |
#symbolize ⇒ [:st, (:a, :x), Integer]
See Base#symbolize.
16 17 18 |
# File 'lib/seccomp-tools/instruction/st.rb', line 16 def symbolize [:st, reg.downcase.to_sym, k] end |