| Line | |
|---|
| 1 | #pragma once
|
|---|
| 2 |
|
|---|
| 3 | #include <jenga/include/smoothie/Source.h>
|
|---|
| 4 |
|
|---|
| 5 | #include <Compiler.h>
|
|---|
| 6 |
|
|---|
| 7 | class CDebugSection{
|
|---|
| 8 | public:
|
|---|
| 9 | char szNowFilePath[MAX_PATH];
|
|---|
| 10 |
|
|---|
| 11 | char *buffer;
|
|---|
| 12 | int length;
|
|---|
| 13 |
|
|---|
| 14 |
|
|---|
| 15 | ////////////////////////////////////
|
|---|
| 16 | // デバッグ用の固有情報
|
|---|
| 17 |
|
|---|
| 18 | //イメージベース
|
|---|
| 19 | DWORD dwImageBase;
|
|---|
| 20 |
|
|---|
| 21 | //リライタブルセクションのRVA
|
|---|
| 22 | DWORD dwRVA_RWSection;
|
|---|
| 23 |
|
|---|
| 24 | //コードセクションのRAVとサイズ
|
|---|
| 25 | DWORD dwRVA_CodeSection;
|
|---|
| 26 | int SizeOf_CodeSection;
|
|---|
| 27 |
|
|---|
| 28 | // オブジェクトモジュール
|
|---|
| 29 | ObjectModule objectModule;
|
|---|
| 30 |
|
|---|
| 31 | //インクルード情報
|
|---|
| 32 | INCLUDEFILEINFO IncludeFileInfo;
|
|---|
| 33 |
|
|---|
| 34 | //ソースコード
|
|---|
| 35 | BasicSource source;
|
|---|
| 36 |
|
|---|
| 37 | //コードと行番号の関係
|
|---|
| 38 | SourceLines oldSourceLines;
|
|---|
| 39 |
|
|---|
| 40 | // クラス情報
|
|---|
| 41 | Classes *pobj_DBClass;
|
|---|
| 42 |
|
|---|
| 43 | //定数を取得
|
|---|
| 44 | Consts globalConsts;
|
|---|
| 45 | ConstMacros globalConstMacros;
|
|---|
| 46 |
|
|---|
| 47 | //グローバル実行領域のサイズ
|
|---|
| 48 | int GlobalOpBufferSize;
|
|---|
| 49 |
|
|---|
| 50 | //プロシージャ
|
|---|
| 51 | UserProcs userProcs;
|
|---|
| 52 |
|
|---|
| 53 | const UserProc *pSub_DebugSys_EndProc;
|
|---|
| 54 |
|
|---|
| 55 | //ネイティブコードバッファ
|
|---|
| 56 | char *OpBuffer;
|
|---|
| 57 |
|
|---|
| 58 | //シングルステップ用コードバッファ
|
|---|
| 59 | char *SingleStepCodeBuffer;
|
|---|
| 60 |
|
|---|
| 61 | //ブレークポイント用コードバッファ
|
|---|
| 62 | char *BreakStepCodeBuffer;
|
|---|
| 63 |
|
|---|
| 64 |
|
|---|
| 65 | ////////////////////////////////////
|
|---|
| 66 |
|
|---|
| 67 |
|
|---|
| 68 | CDebugSection()
|
|---|
| 69 | : buffer( NULL )
|
|---|
| 70 | , length( 0 )
|
|---|
| 71 | , dwImageBase( 0 )
|
|---|
| 72 | , dwRVA_RWSection( 0 )
|
|---|
| 73 | , dwRVA_CodeSection( 0 )
|
|---|
| 74 | , SizeOf_CodeSection( 0 )
|
|---|
| 75 | , pobj_DBClass( NULL )
|
|---|
| 76 | , GlobalOpBufferSize( 0 )
|
|---|
| 77 | , pSub_DebugSys_EndProc( NULL )
|
|---|
| 78 | , OpBuffer( NULL )
|
|---|
| 79 | , SingleStepCodeBuffer( NULL )
|
|---|
| 80 | , BreakStepCodeBuffer( NULL )
|
|---|
| 81 | {
|
|---|
| 82 | szNowFilePath[0]=0;
|
|---|
| 83 | }
|
|---|
| 84 | ~CDebugSection();
|
|---|
| 85 |
|
|---|
| 86 | void make(void);
|
|---|
| 87 | private:
|
|---|
| 88 | void UpdateBreakPoint(void);
|
|---|
| 89 | char *MakeSingleStepCode(void);
|
|---|
| 90 | BOOL __load(void);
|
|---|
| 91 | public:
|
|---|
| 92 | BOOL load(HMODULE hModule);
|
|---|
| 93 |
|
|---|
| 94 | void choice(void);
|
|---|
| 95 |
|
|---|
| 96 | void DeleteDebugInfo(void);
|
|---|
| 97 | };
|
|---|
| 98 |
|
|---|
| 99 | class CDBDebugSection{
|
|---|
| 100 | public:
|
|---|
| 101 | CDebugSection **ppobj_ds;
|
|---|
| 102 | int num;
|
|---|
| 103 |
|
|---|
| 104 | CDebugSection *pobj_now;
|
|---|
| 105 |
|
|---|
| 106 | CDBDebugSection();
|
|---|
| 107 | ~CDBDebugSection();
|
|---|
| 108 |
|
|---|
| 109 | BOOL add(HMODULE hModule);
|
|---|
| 110 | void del(HMODULE hModule);
|
|---|
| 111 |
|
|---|
| 112 | void choice(int index);
|
|---|
| 113 |
|
|---|
| 114 | };
|
|---|
| 115 |
|
|---|
| 116 | extern CDBDebugSection *pobj_DBDebugSection;
|
|---|
Note:
See
TracBrowser
for help on using the repository browser.