Main Page | Class Hierarchy | Class List | File List | Class Members | File Members

ilopc.h

Go to the documentation of this file.
00001 /*
00002  *      HT Editor
00003  *      ilopc.h
00004  *
00005  *      Copyright (C) 1999-2002 Sebastian Biallas (sb@web-productions.de)
00006  *
00007  *      This program is free software; you can redistribute it and/or modify
00008  *      it under the terms of the GNU General Public License version 2 as
00009  *      published by the Free Software Foundation.
00010  *
00011  *      This program is distributed in the hope that it will be useful,
00012  *      but WITHOUT ANY WARRANTY; without even the implied warranty of
00013  *      MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00014  *      GNU General Public License for more details.
00015  *
00016  *      You should have received a copy of the GNU General Public License
00017  *      along with this program; if not, write to the Free Software
00018  *      Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
00019  */
00020 
00021 #ifndef ILOPC_H
00022 #define ILOPC_H
00023 
00024 #include "global.h"
00025 
00026 #define MAX_IL_OPCODE 256
00027 #define MAX_IL_OPCODE_PREFIX 36
00028 
00029 #define IL_OPCODE_ARGS_INVALID          0
00030 #define IL_OPCODE_ARGS_NONE                     1
00031 #define IL_OPCODE_ARGS_INT8                     2
00032 #define IL_OPCODE_ARGS_UINT8            3
00033 #define IL_OPCODE_ARGS_INT16            4
00034 #define IL_OPCODE_ARGS_UINT16           5
00035 #define IL_OPCODE_ARGS_INT32            6
00036 #define IL_OPCODE_ARGS_INT64            7
00037 #define IL_OPCODE_ARGS_FLOAT32          8
00038 #define IL_OPCODE_ARGS_FLOAT64          9
00039 #define IL_OPCODE_ARGS_TOKEN          10
00040 #define IL_OPCODE_ARGS_SHORT_VAR      11
00041 #define IL_OPCODE_ARGS_LONG_VAR         12
00042 #define IL_OPCODE_ARGS_SHORT_ARG      13
00043 #define IL_OPCODE_ARGS_LONG_ARG         14
00044 #define IL_OPCODE_ARGS_SHORT_JUMP       15
00045 #define IL_OPCODE_ARGS_LONG_JUMP      16
00046 #define IL_OPCODE_ARGS_CALL                     17
00047 #define IL_OPCODE_ARGS_CALLI            18
00048 #define IL_OPCODE_ARGS_CALLVIRT         19
00049 #define IL_OPCODE_ARGS_SWITCH           20
00050 #define IL_OPCODE_ARGS_STRING           21
00051 #define IL_OPCODE_ARGS_NEW                      22
00052 #define IL_OPCODE_ARGS_ANN_DATA         23
00053 #define IL_OPCODE_ARGS_ANN_DEAD         24
00054 #define IL_OPCODE_ARGS_ANN_REF          25
00055 #define IL_OPCODE_ARGS_ANN_PHI          26
00056 #define IL_OPCODE_ARGS_ANN_LIVE         27
00057 #define IL_OPCODE_ARGS_ANN_ARG          28
00058 
00059 #define IL_OPCODE_ARGS_PREFIX           29
00060 
00061 // meta
00062 #define IL_META_TOKEN_MASK              0xff000000
00063 #define IL_META_TOKEN_MODULE            0x00000000
00064 #define IL_META_TOKEN_TYPE_REF          0x01000000
00065 #define IL_META_TOKEN_TYPE_DEF          0x02000000
00066 #define IL_META_TOKEN_FIELD_DEF         0x04000000
00067 #define IL_META_TOKEN_METHOD_DEF        0x06000000
00068 #define IL_META_TOKEN_PARAM_DEF         0x08000000
00069 #define IL_META_TOKEN_INTERFACE_IMPL    0x09000000
00070 #define IL_META_TOKEN_MEMBER_REF        0x0a000000
00071 #define IL_META_TOKEN_CONSTANT          0x0b000000
00072 #define IL_META_TOKEN_CUSTOM_ATTRIBUTE  0x0c000000
00073 #define IL_META_TOKEN_CUSTOM_VALUE      IL_META_TOKEN_CUSTOM_ATTRIBUTE
00074 #define IL_META_TOKEN_FIELD_MARSHAL     0x0d000000
00075 #define IL_META_TOKEN_DECL_SECURITY     0x0e000000
00076 #define IL_META_TOKEN_CLASS_LAYOUT      0x0f000000
00077 #define IL_META_TOKEN_FIELD_LAYOUT      0x10000000
00078 #define IL_META_TOKEN_STAND_ALONE_SIG   0x11000000
00079 #define IL_META_TOKEN_EVENT_MAP         0x12000000
00080 #define IL_META_TOKEN_EVENT             0x14000000
00081 #define IL_META_TOKEN_PROPERTY_MAP      0x15000000
00082 #define IL_META_TOKEN_PROPERTY          0x17000000
00083 #define IL_META_TOKEN_METHOD_SEMANTICS  0x18000000
00084 #define IL_META_TOKEN_METHOD_IMPL       0x19000000
00085 #define IL_META_TOKEN_MODULE_REF        0x1a000000
00086 #define IL_META_TOKEN_TYPE_SPEC         0x1b000000
00087 #define IL_META_TOKEN_IMPL_MAP          0x1c000000
00088 #define IL_META_TOKEN_FIELD_RVA         0x1d000000
00089 #define IL_META_TOKEN_ASSEMBLY          0x20000000
00090 #define IL_META_TOKEN_PROCESSOR_DEF     0x21000000
00091 #define IL_META_TOKEN_OS_DEF            0x22000000
00092 #define IL_META_TOKEN_ASSEMBLY_REF      0x23000000
00093 #define IL_META_TOKEN_PROCESSOR_REF     0x24000000
00094 #define IL_META_TOKEN_OS_REF            0x25000000
00095 #define IL_META_TOKEN_FILE              0x26000000
00096 #define IL_META_TOKEN_EXPORTED_TYPE     0x27000000
00097 #define IL_META_TOKEN_MANIFEST_RESOURCE 0x28000000
00098 #define IL_META_TOKEN_NESTED_CLASS      0x29000000
00099 #define IL_META_TOKEN_STRING            0x70000000
00100 #define IL_META_TOKEN_NAME              0x71000000
00101 #define IL_META_TOKEN_BASE_TYPE         0x72000000
00102 
00103 
00104 struct ILOpcodeTabEntry {
00105         char *name;
00106         byte    op;
00107         byte size;
00108 };
00109                                                                 
00110 extern ILOpcodeTabEntry il_opcode_table[MAX_IL_OPCODE];
00111 extern ILOpcodeTabEntry il_prefix_opcode_table[MAX_IL_OPCODE_PREFIX];
00112 
00113 #endif
00114  

Generated on Fri May 7 21:15:40 2004 by doxygen 1.3.5