00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00019 #ifndef DXCUT_DEBUG_INFO_H
00020 #define DXCUT_DEBUG_INFO_H
00021 #include <dxcut/dex.h>
00022 #ifdef __cplusplus
00023 extern "C" {
00024 #endif
00025
00032 typedef enum DexDebugOpCode {
00033 DBG_END_SEQUENCE = 0x00,
00034 DBG_ADVANCE_PC = 0x01,
00035 DBG_ADVANCE_LINE = 0x02,
00036 DBG_START_LOCAL = 0x03,
00037 DBG_START_LOCAL_EXTENDED = 0x04,
00038 DBG_END_LOCAL = 0x05,
00039 DBG_RESTART_LOCAL = 0x06,
00040 DBG_SET_PROLOGUE_END = 0x07,
00041 DBG_SET_EPILOGUE_BEGIN = 0x08,
00042 DBG_SET_FILE = 0x09,
00043 DBG_FIRST_SPECIAL = 0x0a
00044 } DexDebugOpCode;
00045
00046 typedef struct {
00048 dx_ubyte opcode;
00050 union {
00051 dx_uint addr_diff;
00052 dx_uint line_diff;
00053 struct {
00054 dx_uint register_num;
00055 ref_str* name;
00056 ref_str* type;
00057 ref_str* sig;
00058 }* start_local;
00059 dx_uint register_num;
00060 ref_str* name;
00061 } p;
00062 } DexDebugInstruction;
00063
00064 typedef struct {
00066 dx_uint line_start;
00067
00071 ref_strstr* parameter_names;
00072
00075 DexDebugInstruction* insns;
00076 } DexDebugInfo;
00077
00082 extern
00083 void dxc_free_debug_info(DexDebugInfo* debug_info);
00084
00085 #ifdef __cplusplus
00086 }
00087 #endif
00088 #endif // DXCUT_DEBUG_INFO