Changeset 357 in dev for trunk/abdev/BasicCompiler64
- Timestamp:
- Nov 5, 2007, 3:26:20 AM (17 years ago)
- Location:
- trunk/abdev/BasicCompiler64
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/abdev/BasicCompiler64/CodeGenerator.cpp
r317 r357 157 157 /////////////////// 158 158 159 void CodeGenerator::op_mov_RV(int op_size,int reg,long i32data, Schedule::Type scheduleType ){159 const PertialSchedule *CodeGenerator::op_mov_RV(int op_size,int reg,long i32data, Schedule::Type scheduleType, bool isPertialSchedule ){ 160 160 //mov reg,i32data 161 161 … … 176 176 177 177 //即値 178 const PertialSchedule *pPertialSchedule = NULL; 179 if( isPertialSchedule ) 180 { 181 pertialSchedules.push_back( new PertialSchedule( pNativeCode->GetSize(), sizeof(long) ) ); 182 pPertialSchedule = pertialSchedules.back(); 183 } 178 184 pNativeCode->PutEx( i32data, scheduleType ); 179 } 180 void CodeGenerator::op_mov_RV64(int reg,_int64 i64data){ 185 186 return pPertialSchedule; 187 } 188 const PertialSchedule *CodeGenerator::op_mov_RV64( int reg, _int64 i64data, bool isPertialSchedule ) 189 { 181 190 //mov reg,i64data 182 191 … … 188 197 189 198 //即値 199 const PertialSchedule *pPertialSchedule = NULL; 200 if( isPertialSchedule ) 201 { 202 pertialSchedules.push_back( new PertialSchedule( pNativeCode->GetSize(), sizeof(_int64) ) ); 203 pPertialSchedule = pertialSchedules.back(); 204 } 190 205 pNativeCode->Put( i64data ); 206 207 return pPertialSchedule; 191 208 } 192 209 const PertialSchedule *CodeGenerator::op_mov_RM(int op_size,int reg,int base_reg,long offset,char mod, Schedule::Type scheduleType, bool isPertialSchedule ){ -
trunk/abdev/BasicCompiler64/Compile_Func.cpp
r349 r357 16 16 if( lstrcmpi( FuncName, "__delegate_dynamicmethod_call" ) == 0 ) return FUNC_DELEGATE_DYNAMICMETHOD_CALL; 17 17 if( lstrcmpi( FuncName, "__delegate_staticmethod_call" ) == 0 ) return FUNC_DELEGATE_STATICMETHOD_CALL; 18 if( lstrcmpi( FuncName, "_System_GetNowScopeCatchAddresses" ) == 0 )return FUNC_SYSTEM_GET_NOW_SCOPE_CATCH_ADDRESS; 18 19 if( lstrcmpi( FuncName, "GetDouble" ) == 0 ) return FUNC_GETDOUBLE; 19 20 if( lstrcmpi( FuncName, "GetSingle" ) == 0 ) return FUNC_GETSINGLE; … … 441 442 } 442 443 444 void Opcode_Func_System_Get_Bp() 445 { 446 //mov rax,rbp 447 compiler.codeGenerator.op_mov_RR(REG_RAX,REG_RBP); 448 } 449 443 450 void Opcode_Func_GetPtrData( const char *Parameter, const int type ){ 444 451 int reg=REG_RAX; … … 492 499 Opcode_Func_delegate_call( Parameter, resultType, false, isCallOn ); 493 500 break; 501 case FUNC_SYSTEM_GET_NOW_SCOPE_CATCH_ADDRESS: 502 if( isCallOn ) Exception::Opcode_Func_System_GetNowScopeCatchAddress(); 503 resultType.SetBasicType( DEF_LONG ); 504 break; 505 case FUNC_SYSTEM_GET_BP: 506 if( isCallOn ) Opcode_Func_System_Get_Bp(); 507 resultType.SetBasicType( DEF_LONG ); 508 break; 494 509 495 510 case FUNC_GETDOUBLE: -
trunk/abdev/BasicCompiler64/FunctionValue.h
r330 r357 16 16 #define FUNC_DELEGATE_DYNAMICMETHOD_CALL 0x0621 17 17 #define FUNC_DELEGATE_STATICMETHOD_CALL 0x0622 18 #define FUNC_SYSTEM_GET_NOW_SCOPE_CATCH_ADDRESS 0x0623 19 #define FUNC_SYSTEM_GET_BP 0x0624 18 20 19 21 //ポインタ -
trunk/abdev/BasicCompiler64/MakePeHdr.cpp
r355 r357 1077 1077 compiler.linker.SetImageBase( ImageBase ); 1078 1078 compiler.linker.ResolveDataTableSchedules( MemPos_DataSection ); 1079 compiler.linker.ResolveCatchAddressSchedules( MemPos_CodeSection ); 1079 1080 compiler.linker.ResolveDllProcSchedules( MemPos_CodeSection, MemPos_ImportSection, LookupSize, HintSize ); 1080 1081 compiler.linker.ResolveUserProcSchedules( MemPos_CodeSection );
Note:
See TracChangeset
for help on using the changeset viewer.