Beispiel #1
0
        protected Architecture(Process process, TargetInfo info)
        {
            this.process = process;
            this.TargetInfo = info;

            if (!Inferior.IsRunningOnWindows)
                disassembler = new BfdDisassembler (process, info.TargetAddressSize == 8);
            if (info.TargetAddressSize == 8)
                opcodes = new Opcodes_X86_64 (process);
            else
                opcodes = new Opcodes_I386 (process);
        }
 public static X86_Instruction DecodeInstruction(X86_Opcodes opcodes,
                                                 TargetMemoryAccess memory,
                                                 TargetAddress address)
 {
     try {
         X86_Instruction insn;
         if (memory.TargetMemoryInfo.TargetAddressSize == 8)
         {
             insn = new Instruction_X86_64(opcodes, address);
         }
         else
         {
             insn = new Instruction_I386(opcodes, address);
         }
         insn.DoDecodeInstruction(memory, address);
         return(insn);
     } catch {
         return(null);
     }
 }
 protected X86_Instruction(X86_Opcodes opcodes, TargetAddress address)
 {
     this.Opcodes = opcodes;
     this.address = address;
 }
Beispiel #4
0
 internal Instruction_X86_64(X86_Opcodes opcodes, TargetAddress address)
     : base(opcodes, address)
 {
 }
Beispiel #5
0
 internal Instruction_X86_64(X86_Opcodes opcodes, TargetAddress address)
     : base(opcodes, address)
 {
 }
Beispiel #6
0
 protected X86_Instruction(X86_Opcodes opcodes, TargetAddress address)
 {
     this.Opcodes = opcodes;
     this.address = address;
 }
Beispiel #7
0
        public static X86_Instruction DecodeInstruction(X86_Opcodes opcodes,
								 TargetMemoryAccess memory,
								 TargetAddress address)
        {
            try {
                X86_Instruction insn;
                if (memory.TargetMemoryInfo.TargetAddressSize == 8)
                    insn = new Instruction_X86_64 (opcodes, address);
                else
                    insn = new Instruction_I386 (opcodes, address);
                insn.DoDecodeInstruction (memory, address);
                return insn;
            } catch {
                return null;
            }
        }