Changeset 828 in dev for trunk/ab5.0/abdev/BasicCompiler_Common/Diagnose.cpp
- Timestamp:
- Mar 19, 2012, 1:59:48 AM (13 years ago)
- Location:
- trunk
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk
-
Property svn:mergeinfo
set to
/branches/egtra merged eligible
-
Property svn:mergeinfo
set to
-
trunk/ab5.0/abdev
-
Property svn:ignore
set to
*.opensdf
*.sdf
*.suo
*.user
int
ipch
out
-
Property svn:ignore
set to
-
trunk/ab5.0/abdev/BasicCompiler_Common/Diagnose.cpp
r750 r828 34 34 int codeSizeOfGlobalProc = 0; 35 35 int codeSizeOfClassMethod = 0; 36 compiler.GetObjectModule().meta.GetUserProcs().Iterator_Reset(); 37 while( compiler.GetObjectModule().meta.GetUserProcs().Iterator_HasNext() ) 36 foreach (auto pUserProc, compiler.GetObjectModule().meta.GetUserProcs()) 38 37 { 39 UserProc *pUserProc = compiler.GetObjectModule().meta.GetUserProcs().Iterator_GetNext();40 38 if( pUserProc->IsCompiled() ){ 41 39 if( pUserProc->HasParentClass() ){ … … 60 58 int codeSizeOfEnum = 0; 61 59 62 // イテレータをリセット 63 compiler.GetObjectModule().meta.GetClasses().Iterator_Reset(); 64 65 while( compiler.GetObjectModule().meta.GetClasses().Iterator_HasNext() ){ 60 foreach (auto pClass, compiler.GetObjectModule().meta.GetClasses()) 61 { 66 62 int codeSizeOfClass = 0; 67 63 68 CClass &objClass = * compiler.GetObjectModule().meta.GetClasses().Iterator_GetNext();64 CClass &objClass = *pClass; 69 65 70 66 if( !objClass.IsEnum() ){ … … 82 78 // 静的メソッド 83 79 foreach( const CMethod *pMethod, objClass.GetStaticMethods() ){ 84 80 codeSizeOfClass += pMethod->GetUserProc().GetCodeSize(); 85 81 } 86 82 … … 99 95 /////////////////////////////////////////////////////////////////// 100 96 101 // イテレータをリセット 102 compiler.GetObjectModule().meta.GetClasses().Iterator_Reset(); 103 104 while( compiler.GetObjectModule().meta.GetClasses().Iterator_HasNext() ){ 97 foreach (auto pClass, compiler.GetObjectModule().meta.GetClasses()) 98 { 105 99 int codeSizeOfClass = 0; 106 100 107 CClass &objClass = * compiler.GetObjectModule().meta.GetClasses().Iterator_GetNext();101 CClass &objClass = *pClass; 108 102 109 103 // 動的メソッド … … 116 110 // 静的メソッド 117 111 foreach( const CMethod *pMethod, objClass.GetStaticMethods() ){ 118 112 codeSizeOfClass += pMethod->GetUserProc().GetCodeSize(); 119 113 } 120 114 121 if( codeSizeOfClass ){ 122 temporary[0]=0; 123 lstrcat( temporary, "------------------------------------------------------------------\n" ); 124 sprintf( temporary + lstrlen(temporary), "【 %s クラスのコード情報】\n", objClass.GetName().c_str() ); 125 sprintf( temporary + lstrlen(temporary), "class code size: %d bytes\n", codeSizeOfClass ); 126 lstrcat( temporary, "------------------------------------------------------------------\n" ); 127 lstrcat( temporary, "\n" ); 115 if( codeSizeOfClass ) 116 { 117 sprintf(temporary, 118 "------------------------------------------------------------------\n" 119 "【 %s クラスのコード情報】\n" 120 "class code size: %d bytes\n" 121 "------------------------------------------------------------------\n" 122 "\n", 123 objClass.GetName().c_str(), codeSizeOfClass); 128 124 trace_for_size( temporary ); 129 125 }
Note:
See TracChangeset
for help on using the changeset viewer.