Ignore:
Timestamp:
Sep 26, 2008, 11:49:14 PM (16 years ago)
Author:
イグトランス (egtra)
Message:

マクロBUILD_X64_COMPILERの導入

Location:
branches/x64_compiler_on_32/abdev/BasicCompiler_Common
Files:
26 edited

Legend:

Unmodified
Added
Removed
  • branches/x64_compiler_on_32/abdev/BasicCompiler_Common/CDebugThreadInfo.cpp

    r741 r759  
    2222
    2323BOOL CDebugThreadInfo::Reflesh(int ThreadNum){
     24#if defined _WIN64 || !defined BUILD_X64_COMPILER
    2425    Free();
    2526
     
    102103
    103104    return 1;
     105#else
     106    return 0;
     107#endif
    104108}
    105109
  • branches/x64_compiler_on_32/abdev/BasicCompiler_Common/Compile.cpp

    r743 r759  
    77#include "../BasicCompiler_Common/common.h"
    88
    9 #ifdef _AMD64_
     9#if defined _AMD64_ || defined BUILD_X64_COMPILER
    1010#include "../compiler_x64/opcode.h"
    1111#else
  • branches/x64_compiler_on_32/abdev/BasicCompiler_Common/DebugMiddleFile.cpp

    r750 r759  
    33#include "../BasicCompiler_Common/DebugSection.h"
    44
    5 #ifdef _AMD64_
     5#if defined _AMD64_ || defined BUILD_X64_COMPILER
    66#include "../compiler_x64/opcode.h"
    77#else
     
    104104        // オブジェクトモジュールリストに類似したソースコードリストを作成
    105105        BasicSources sources;
     106        sources.reserve( compiler.staticLibraries.size() );
    106107        foreach( const ObjectModule *pObjectModule, compiler.staticLibraries )
    107108        {
     
    240241    int maxLineInfoNum = *(long *)(buffer+i2);
    241242    i2+=sizeof(long);
     243    _oldSourceLines.reserve( maxLineInfoNum );
    242244    for(i3=0;i3<maxLineInfoNum;i3++){
    243245        int nativeCodePos = *(long *)(buffer+i2);
     
    319321
    320322    int pe_size;
    321 #ifdef _AMD64_
     323#if defined _AMD64_ || defined BUILD_X64_COMPILER
    322324    IMAGE_NT_HEADERS64 pe_hdr;
    323325    pe_size=sizeof(IMAGE_NT_HEADERS64);
  • branches/x64_compiler_on_32/abdev/BasicCompiler_Common/Diagnose.cpp

    r750 r759  
    33#include "../BasicCompiler_Common/common.h"
    44
    5 #ifdef _AMD64_
     5#if defined _AMD64_ || defined BUILD_X64_COMPILER
    66#include "../compiler_x64/opcode.h"
    77#else
  • branches/x64_compiler_on_32/abdev/BasicCompiler_Common/MakeExe.cpp

    r750 r759  
    192192
    193193            char coreFilePath[MAX_PATH];
    194 #if defined _AMD64_
     194#if defined _AMD64_ || defined BUILD_X64_COMPILER
    195195            sprintf( coreFilePath, "..\\lib\\x64\\%s", coreFileName );
    196196#else
  • branches/x64_compiler_on_32/abdev/BasicCompiler_Common/Object.cpp

    r485 r759  
    55#include "../BasicCompiler_Common/common.h"
    66
    7 #ifdef _AMD64_
     7#if defined _AMD64_ || defined BUILD_X64_COMPILER
    88#include "../compiler_x64/opcode.h"
    99#else
  • branches/x64_compiler_on_32/abdev/BasicCompiler_Common/OldStatement.cpp

    r485 r759  
    33#include "common.h"
    44
    5 #ifdef _AMD64_
     5#if defined _AMD64_ || defined BUILD_X64_COMPILER
    66#include "../compiler_x64/opcode.h"
    77#else
  • branches/x64_compiler_on_32/abdev/BasicCompiler_Common/Overload.cpp

    r485 r759  
    33#include "../BasicCompiler_Common/common.h"
    44
    5 #ifdef _AMD64_
     5#if defined _AMD64_ || defined BUILD_X64_COMPILER
    66#include "../compiler_x64/opcode.h"
    77#else
  • branches/x64_compiler_on_32/abdev/BasicCompiler_Common/PESchedule.cpp

    r750 r759  
    55#include "../BasicCompiler_Common/common.h"
    66
    7 #ifdef _AMD64_
     7#if defined _AMD64_ || defined BUILD_X64_COMPILER
    88#include "../compiler_x64/opcode.h"
    99#else
  • branches/x64_compiler_on_32/abdev/BasicCompiler_Common/ParamImpl.cpp

    r750 r759  
    11#include "stdafx.h"
    22
    3 #ifdef _AMD64_
     3#if defined _AMD64_ || defined BUILD_X64_COMPILER
    44#include "../compiler_x64/opcode.h"
    55#else
  • branches/x64_compiler_on_32/abdev/BasicCompiler_Common/RSrcSection.cpp

    r750 r759  
    864864
    865865        //プラットフォームをセット
    866 #ifdef _AMD64_
     866#if defined _AMD64_ || defined BUILD_X64_COMPILER
    867867        temporary=PermutationString(temporary,"#PLATFORM#","amd64");
    868868#else
  • branches/x64_compiler_on_32/abdev/BasicCompiler_Common/Subroutine.cpp

    r751 r759  
    11#include "stdafx.h"
    22
    3 #ifdef _AMD64_
     3#if defined _AMD64_ || defined BUILD_X64_COMPILER
    44#include "../compiler_x64/opcode.h"
    55#else
  • branches/x64_compiler_on_32/abdev/BasicCompiler_Common/VariableOpe.cpp

    r750 r759  
    11#include "stdafx.h"
    22
    3 #ifdef _AMD64_
     3#if defined _AMD64_ || defined BUILD_X64_COMPILER
    44#include "../compiler_x64/opcode.h"
    55#else
     
    7474            break;
    7575    }
    76 #ifdef _AMD64_
     76#if defined _AMD64_ || defined BUILD_X64_COMPILER
    7777    return IsPtrType(type);
    7878#else
     
    9393            break;
    9494    }
    95 #ifdef _AMD64_
     95#if defined _AMD64_ || defined BUILD_X64_COMPILER
    9696    if(IsPtrType(type)) return DEF_INT64;
    9797#else
  • branches/x64_compiler_on_32/abdev/BasicCompiler_Common/WatchList.cpp

    r750 r759  
    55#include "common.h"
    66
    7 #ifdef _AMD64_
     7#if defined _AMD64_ || defined BUILD_X64_COMPILER
    88#include "../compiler_x64/opcode.h"
    99#else
  • branches/x64_compiler_on_32/abdev/BasicCompiler_Common/calculation.cpp

    r672 r759  
    55#include "../BasicCompiler_Common/common.h"
    66
    7 #ifdef _AMD64_
     7#if defined _AMD64_ || defined BUILD_X64_COMPILER
    88#include "../compiler_x64/opcode.h"
    99#else
  • branches/x64_compiler_on_32/abdev/BasicCompiler_Common/common.h

    r702 r759  
    66#include <option.h>
    77
    8 #ifdef _AMD64_
     8#if defined _AMD64_ || defined BUILD_X64_COMPILER
    99#include "../compiler_x64/resource.h"
    1010#include "../compiler_x64/CommandValue.h"
     
    3939
    4040
    41 #ifdef _AMD64_
     41#if defined _AMD64_ || defined BUILD_X64_COMPILER
    4242    #define PLATFORM    64
    4343#else
     
    5555#endif
    5656
    57 #ifdef _AMD64_
     57#if defined _AMD64_ || defined BUILD_X64_COMPILER
    5858    #ifndef IMAGE_SIZEOF_NT_OPTIONAL64_HEADER
    5959        #define IMAGE_SIZEOF_NT_OPTIONAL64_HEADER    240
  • branches/x64_compiler_on_32/abdev/BasicCompiler_Common/gc.cpp

    r508 r759  
    33#include <Compiler.h>
    44
    5 #ifdef _AMD64_
     5#if defined _AMD64_ || defined BUILD_X64_COMPILER
    66#include "../compiler_x64/opcode.h"
    77#else
  • branches/x64_compiler_on_32/abdev/BasicCompiler_Common/hash.cpp

    r598 r759  
    55#include "../BasicCompiler_Common/common.h"
    66
    7 #ifdef _AMD64_
     7#if defined _AMD64_ || defined BUILD_X64_COMPILER
    88#include "../compiler_x64/opcode.h"
    99#else
  • branches/x64_compiler_on_32/abdev/BasicCompiler_Common/include/CodeGenerator.h

    r641 r759  
    33#include <LexicalScope.h>
    44
    5 #ifdef _AMD64_
     5#if defined _AMD64_ || defined BUILD_X64_COMPILER
    66#include "../../compiler_x64/MachineFixed.h"
    77#else
     
    303303
    304304
    305 #ifdef _AMD64_
     305#if defined _AMD64_ || defined BUILD_X64_COMPILER
    306306    /////////////////////////////////////////////////////////////////
    307307    // 64ビット機械語生成
  • branches/x64_compiler_on_32/abdev/BasicCompiler_Common/include/ver.h

    r388 r759  
    77#ifdef _AMD64_
    88#define VER_INFO        "(x64)"
     9#elif defined BUILD_X64_COMPILER
     10#define VER_INFO        "(x64 on x86)"
    911#else
    1012#define VER_INFO        ""
  • branches/x64_compiler_on_32/abdev/BasicCompiler_Common/src/CommonCodeGenerator.cpp

    r750 r759  
    33#include <CodeGenerator.h>
    44
    5 #ifdef _AMD64_
     5#if defined _AMD64_ || defined BUILD_X64_COMPILER
    66#include "../../compiler_x64/opcode.h"
    77#else
     
    329329void CodeGenerator::op_AddNeedFreeTempStructure( int reg )
    330330{
    331 #ifdef _AMD64_
     331#if defined _AMD64_ || defined BUILD_X64_COMPILER
    332332    //////////////////////////////////////////////////////
    333333    /////    レジスタ資源のバックアップ
  • branches/x64_compiler_on_32/abdev/BasicCompiler_Common/src/Exception.cpp

    r750 r759  
    11#include "stdafx.h"
    22
    3 #ifdef _AMD64_
     3#if defined _AMD64_ || defined BUILD_X64_COMPILER
    44#include "../../compiler_x64/opcode.h"
    55#else
     
    395395    }
    396396
    397 #ifdef _WIN64
     397#if defined _WIN64 || defined BUILD_X64_COMPILER
    398398    //mov rax,catchAddress
    399399    const PertialSchedule *pPertialSchedule = compiler.codeGenerator.op_mov_RV( sizeof(long), REG_RAX, 0, Schedule::DataTable, true );
     
    408408    int dataTableOffset = compiler.GetObjectModule().dataTable.Add( static_cast<LONG_PTR>(0) );
    409409
    410 #ifdef _WIN64
     410#if defined _WIN64 || defined BUILD_X64_COMPILER
    411411    //mov rax,dataTableOffset
    412412    compiler.codeGenerator.op_mov_RV( sizeof(_int64), REG_RAX, dataTableOffset, Schedule::DataTable);
     
    426426    }
    427427
    428 #ifdef _WIN64
     428#if defined _WIN64 || defined BUILD_X64_COMPILER
    429429    //mov rax,finallyAddress
    430430    const PertialSchedule *pPertialSchedule = compiler.codeGenerator.op_mov_RV( sizeof(long), REG_RAX, 0, Schedule::CatchAddress, true );
     
    439439    int dataTableOffset = compiler.GetObjectModule().dataTable.Add( static_cast<LONG_PTR>(0) );
    440440
    441 #ifdef _WIN64
     441#if defined _WIN64 || defined BUILD_X64_COMPILER
    442442    //mov rax,dataTableOffset
    443443    compiler.codeGenerator.op_mov_RV( sizeof(_int64), REG_RAX, dataTableOffset, Schedule::DataTable);
  • branches/x64_compiler_on_32/abdev/BasicCompiler_Common/src/LexicalAnalyzer_Class.cpp

    r750 r759  
    22
    33#include "../common.h"
    4 #ifdef _AMD64_
     4#if defined _AMD64_ || defined BUILD_X64_COMPILER
    55#include "../../compiler_x64/opcode.h"
    66#else
  • branches/x64_compiler_on_32/abdev/BasicCompiler_Common/src/LexicalScope.cpp

    r750 r759  
    66#include "../common.h"
    77
    8 #ifdef _AMD64_
     8#if defined _AMD64_ || defined BUILD_X64_COMPILER
    99#include "../../compiler_x64/opcode.h"
    1010#else
     
    125125            //メモリを解放する
    126126
    127 #ifdef _AMD64_
     127#if defined _AMD64_ || defined BUILD_X64_COMPILER
    128128            //x64ビットコード
    129129
  • branches/x64_compiler_on_32/abdev/BasicCompiler_Common/src/Linker.cpp

    r750 r759  
    2222        if( schedule.GetType() == Schedule::DataTable )
    2323        {
    24 #ifdef _WIN64
     24#if defined _WIN64 || defined BUILD_X64_COMPILER
    2525            dataTable.OverwriteInt64(
    2626                schedule.GetOffset(),
     
    6262            {
    6363                // 置き換える値が0の場合を除く
    64 #ifdef _WIN64
     64#if defined _WIN64 || defined BUILD_X64_COMPILER
    6565                dataTable.OverwriteInt64(
    6666                    schedule.GetOffset(),
     
    8585        if( schedule.GetType() == Schedule::DllProc )
    8686        {
    87 #ifdef _AMD64_
     87#if defined _AMD64_ || defined BUILD_X64_COMPILER
    8888            nativeCode.Overwrite(
    8989                schedule.GetOffset(),
     
    192192            LONG_PTR vtblOffset = schedule.GetClass().GetComVtblOffset();
    193193
    194 #ifdef _WIN64
     194#if defined _WIN64 || defined BUILD_X64_COMPILER
    195195            dataTable.OverwriteInt64(
    196196                schedule.GetOffset(),
     
    209209            LONG_PTR vtblMasterListOffset = schedule.GetClass().GetVtblMasterListOffset();
    210210
    211 #ifdef _WIN64
     211#if defined _WIN64 || defined BUILD_X64_COMPILER
    212212            dataTable.OverwriteInt64(
    213213                schedule.GetOffset(),
     
    232232            LONG_PTR typeInfoDataTableOffset = schedule.GetClass().GetTypeInfoDataTableOffset();
    233233
    234 #ifdef _WIN64
     234#if defined _WIN64 || defined BUILD_X64_COMPILER
    235235            dataTable.OverwriteInt64(
    236236                schedule.GetOffset(),
  • branches/x64_compiler_on_32/abdev/BasicCompiler_Common/src/ProcedureGenerator.cpp

    r750 r759  
    11#include "stdafx.h"
    22
    3 #ifdef _AMD64_
     3#if defined _AMD64_ || defined BUILD_X64_COMPILER
    44#include "../../compiler_x64/opcode.h"
    55#else
Note: See TracChangeset for help on using the changeset viewer.