1 //===-- EDInfo.h - LLVM Enhanced Disassembler -------------------*- C++ -*-===// 2 // 3 // The LLVM Compiler Infrastructure 4 // 5 // This file is distributed under the University of Illinois Open Source 6 // License. See LICENSE.TXT for details. 7 // 8 //===----------------------------------------------------------------------===// 9 10 #ifndef LLVM_EDINFO_H 11 #define LLVM_EDINFO_H 12 13 enum { 14 EDIS_MAX_OPERANDS = 13, 15 EDIS_MAX_SYNTAXES = 2 16 }; 17 18 enum OperandTypes { 19 kOperandTypeNone, 20 kOperandTypeImmediate, 21 kOperandTypeRegister, 22 kOperandTypeX86Memory, 23 kOperandTypeX86EffectiveAddress, 24 kOperandTypeX86PCRelative, 25 kOperandTypeARMBranchTarget, 26 kOperandTypeARMSoReg, 27 kOperandTypeARMSoImm, 28 kOperandTypeARMRotImm, 29 kOperandTypeARMSoImm2Part, 30 kOperandTypeARMPredicate, 31 kOperandTypeAddrModeImm12, 32 kOperandTypeLdStSOReg, 33 kOperandTypeARMAddrMode2, 34 kOperandTypeARMAddrMode2Offset, 35 kOperandTypeARMAddrMode3, 36 kOperandTypeARMAddrMode3Offset, 37 kOperandTypeARMAddrMode4, 38 kOperandTypeARMAddrMode5, 39 kOperandTypeARMAddrMode6, 40 kOperandTypeARMAddrMode6Offset, 41 kOperandTypeARMAddrMode7, 42 kOperandTypeARMAddrModePC, 43 kOperandTypeARMRegisterList, 44 kOperandTypeARMDPRRegisterList, 45 kOperandTypeARMSPRRegisterList, 46 kOperandTypeARMTBAddrMode, 47 kOperandTypeThumbITMask, 48 kOperandTypeThumbAddrModeRegS1, 49 kOperandTypeThumbAddrModeRegS2, 50 kOperandTypeThumbAddrModeRegS4, 51 kOperandTypeThumbAddrModeImmS1, 52 kOperandTypeThumbAddrModeImmS2, 53 kOperandTypeThumbAddrModeImmS4, 54 kOperandTypeThumbAddrModeRR, 55 kOperandTypeThumbAddrModeSP, 56 kOperandTypeThumbAddrModePC, 57 kOperandTypeThumb2AddrModeReg, 58 kOperandTypeThumb2SoReg, 59 kOperandTypeThumb2SoImm, 60 kOperandTypeThumb2AddrModeImm8, 61 kOperandTypeThumb2AddrModeImm8Offset, 62 kOperandTypeThumb2AddrModeImm12, 63 kOperandTypeThumb2AddrModeSoReg, 64 kOperandTypeThumb2AddrModeImm8s4, 65 kOperandTypeThumb2AddrModeImm8s4Offset 66 }; 67 68 enum OperandFlags { 69 kOperandFlagSource = 0x1, 70 kOperandFlagTarget = 0x2 71 }; 72 73 enum InstructionTypes { 74 kInstructionTypeNone, 75 kInstructionTypeMove, 76 kInstructionTypeBranch, 77 kInstructionTypePush, 78 kInstructionTypePop, 79 kInstructionTypeCall, 80 kInstructionTypeReturn 81 }; 82 83 84 #endif 85