#include "trivials.h" #include Op_lahf::Op_lahf(): OpSimple({ 0x9F }) {} // Load flags to AH Op_nop::Op_nop(): OpSimple({ 0x90 }) {} // No operation Op_ret::Op_ret(): OpSimple({ 0xC3 }) {} // near return; TODO: far return is 0xCB Op_syscall::Op_syscall(): OpSimple({ 0x0F, 0x05 }) {} // Syscall Op_ud2::Op_ud2(): OpSimple({ 0x0F, 0x0B }) {} // Undefined Instruction, variant 2: with no operands namespace { bool registered { registerOp("lahf", [](const Asm::Args& args) -> std::shared_ptr{ return std::make_shared(); }) && registerOp("nop", [](const Asm::Args& args) -> std::shared_ptr{ return std::make_shared(); }) && registerOp("ret", [](const Asm::Args& args) -> std::shared_ptr{ return std::make_shared(); }) && registerOp("syscall", [](const Asm::Args& args) -> std::shared_ptr{ return std::make_shared(); }) && registerOp("ud2", [](const Asm::Args& args) -> std::shared_ptr{ return std::make_shared(); }) }; }