Commit c139a9b6 authored by Christian Heimes's avatar Christian Heimes

Fixed PGO builds

The intermediate PG instrument build now lands in Platform-pgi and the final optimized build in Platform-pgo.
parent 6bd238cb
...@@ -23,18 +23,19 @@ set clrpath=%path1% ...@@ -23,18 +23,19 @@ set clrpath=%path1%
if "%1"=="-p" (set platf=%2) & shift & shift & goto CheckOpts if "%1"=="-p" (set platf=%2) & shift & shift & goto CheckOpts
if "%1"=="-2" (set job=%job2%) & (set clrpath=%path2%) & shift & goto CheckOpts if "%1"=="-2" (set job=%job2%) & (set clrpath=%path2%) & shift & goto CheckOpts
set folder=%platf%-pgo set PGI=%platf%-pgi
set PGO=%platf%-pgo
@echo on @echo on
rem build the instrumented version rem build the instrumented version
call build -r -p %platf% -c PGInstrument call build -p %platf% -c PGInstrument
rem remove .pyc files, .pgc files and execute the job rem remove .pyc files, .pgc files and execute the job
%folder%\python.exe rmpyc.py %clrpath% %PGI%\python.exe rmpyc.py %clrpath%
del %folder%\*.pgc del %PGI%\*.pgc
%folder%\python.exe %job% %PGI%\python.exe %job%
rem finally build the optimized version rem finally build the optimized version
call build -r -p %platf% -c PGUpdate if exist %PGO% del /s /q %PGO%
call build -p %platf% -c PGUpdate
...@@ -311,6 +311,7 @@ ...@@ -311,6 +311,7 @@
<Tool <Tool
Name="VCLinkerTool" Name="VCLinkerTool"
AdditionalDependencies="$(bz2Dir)\$(PlatformName)-Release\libbz2.lib" AdditionalDependencies="$(bz2Dir)\$(PlatformName)-Release\libbz2.lib"
ImportLibrary="$(OutDirPGI)\$(TargetName).lib"
/> />
<Tool <Tool
Name="VCALinkTool" Name="VCALinkTool"
...@@ -375,6 +376,7 @@ ...@@ -375,6 +376,7 @@
<Tool <Tool
Name="VCLinkerTool" Name="VCLinkerTool"
AdditionalDependencies="$(bz2Dir)\$(PlatformName)-Release\libbz2.lib" AdditionalDependencies="$(bz2Dir)\$(PlatformName)-Release\libbz2.lib"
ImportLibrary="$(OutDirPGI)\$(TargetName).lib"
TargetMachine="17" TargetMachine="17"
/> />
<Tool <Tool
...@@ -439,6 +441,7 @@ ...@@ -439,6 +441,7 @@
<Tool <Tool
Name="VCLinkerTool" Name="VCLinkerTool"
AdditionalDependencies="$(bz2Dir)\$(PlatformName)-Release\libbz2.lib" AdditionalDependencies="$(bz2Dir)\$(PlatformName)-Release\libbz2.lib"
ImportLibrary="$(OutDirPGI)\$(TargetName).lib"
/> />
<Tool <Tool
Name="VCALinkTool" Name="VCALinkTool"
...@@ -503,6 +506,7 @@ ...@@ -503,6 +506,7 @@
<Tool <Tool
Name="VCLinkerTool" Name="VCLinkerTool"
AdditionalDependencies="$(bz2Dir)\$(PlatformName)-Release\libbz2.lib" AdditionalDependencies="$(bz2Dir)\$(PlatformName)-Release\libbz2.lib"
ImportLibrary="$(OutDirPGI)\$(TargetName).lib"
TargetMachine="17" TargetMachine="17"
/> />
<Tool <Tool
......
...@@ -164,8 +164,6 @@ ...@@ -164,8 +164,6 @@
</Configuration> </Configuration>
<Configuration <Configuration
Name="Debug|Win32" Name="Debug|Win32"
OutputDirectory="$(SolutionDir)$(ConfigurationName)"
IntermediateDirectory="$(ConfigurationName)"
ConfigurationType="1" ConfigurationType="1"
InheritedPropertySheets=".\pyproject.vsprops" InheritedPropertySheets=".\pyproject.vsprops"
UseOfMFC="0" UseOfMFC="0"
......
...@@ -3,8 +3,8 @@ ...@@ -3,8 +3,8 @@
ProjectType="Visual C++" ProjectType="Visual C++"
Version="8.00" Version="8.00"
Name="pginstrument" Name="pginstrument"
OutputDirectory="$(SolutionDir)$(PlatformName)-pgo\" OutputDirectory="$(OutDirPGI)"
IntermediateDirectory="$(SolutionDir)$(PlatformName)-temp-pgo\$(ProjectName)\" IntermediateDirectory="$(SolutionDir)$(PlatformName)-temp-pgi\$(ProjectName)\"
> >
<Tool <Tool
Name="VCCLCompilerTool" Name="VCCLCompilerTool"
...@@ -13,5 +13,11 @@ ...@@ -13,5 +13,11 @@
<Tool <Tool
Name="VCLinkerTool" Name="VCLinkerTool"
LinkTimeCodeGeneration="2" LinkTimeCodeGeneration="2"
ProfileGuidedDatabase="$(SolutionDir)$(PlatformName)-pgi\$(TargetName).pgd"
ImportLibrary="$(OutDirPGI)\$(TargetName).lib"
/>
<UserMacro
Name="OutDirPGI"
Value="$(SolutionDir)$(PlatformName)-pgi\"
/> />
</VisualStudioPropertySheet> </VisualStudioPropertySheet>
...@@ -3,10 +3,12 @@ ...@@ -3,10 +3,12 @@
ProjectType="Visual C++" ProjectType="Visual C++"
Version="8.00" Version="8.00"
Name="pgoptimize" Name="pgoptimize"
OutputDirectory="$(SolutionDir)$(PlatformName)-pgo\"
InheritedPropertySheets="$(SolutionDir)\pginstrument.vsprops" InheritedPropertySheets="$(SolutionDir)\pginstrument.vsprops"
> >
<Tool <Tool
Name="VCLinkerTool" Name="VCLinkerTool"
AdditionalManifestDependencies=""
LinkTimeCodeGeneration="4" LinkTimeCodeGeneration="4"
/> />
</VisualStudioPropertySheet> </VisualStudioPropertySheet>
...@@ -365,6 +365,7 @@ ...@@ -365,6 +365,7 @@
SubSystem="1" SubSystem="1"
StackReserveSize="2000000" StackReserveSize="2000000"
BaseAddress="0x1d000000" BaseAddress="0x1d000000"
ImportLibrary=""
/> />
<Tool <Tool
Name="VCALinkTool" Name="VCALinkTool"
...@@ -439,6 +440,7 @@ ...@@ -439,6 +440,7 @@
SubSystem="1" SubSystem="1"
StackReserveSize="2000000" StackReserveSize="2000000"
BaseAddress="0x1d000000" BaseAddress="0x1d000000"
ImportLibrary=""
TargetMachine="17" TargetMachine="17"
/> />
<Tool <Tool
...@@ -513,6 +515,7 @@ ...@@ -513,6 +515,7 @@
SubSystem="1" SubSystem="1"
StackReserveSize="2000000" StackReserveSize="2000000"
BaseAddress="0x1d000000" BaseAddress="0x1d000000"
ImportLibrary=""
/> />
<Tool <Tool
Name="VCALinkTool" Name="VCALinkTool"
...@@ -587,6 +590,7 @@ ...@@ -587,6 +590,7 @@
SubSystem="1" SubSystem="1"
StackReserveSize="2000000" StackReserveSize="2000000"
BaseAddress="0x1d000000" BaseAddress="0x1d000000"
ImportLibrary=""
TargetMachine="17" TargetMachine="17"
/> />
<Tool <Tool
......
...@@ -373,7 +373,7 @@ ...@@ -373,7 +373,7 @@
IgnoreDefaultLibraryNames="libc" IgnoreDefaultLibraryNames="libc"
ProgramDatabaseFile="$(OutDir)$(PyDllName).pdb" ProgramDatabaseFile="$(OutDir)$(PyDllName).pdb"
BaseAddress="0x1e000000" BaseAddress="0x1e000000"
ImportLibrary="$(OutDir)$(PyDllName).lib" ImportLibrary="$(OutDirPGI)$(PyDllName).lib"
/> />
<Tool <Tool
Name="VCALinkTool" Name="VCALinkTool"
...@@ -448,7 +448,7 @@ ...@@ -448,7 +448,7 @@
IgnoreDefaultLibraryNames="libc" IgnoreDefaultLibraryNames="libc"
ProgramDatabaseFile="$(OutDir)$(PyDllName).pdb" ProgramDatabaseFile="$(OutDir)$(PyDllName).pdb"
BaseAddress="0x1e000000" BaseAddress="0x1e000000"
ImportLibrary="$(OutDir)$(PyDllName).lib" ImportLibrary="$(OutDirPGI)$(PyDllName).lib"
TargetMachine="17" TargetMachine="17"
/> />
<Tool <Tool
...@@ -523,7 +523,7 @@ ...@@ -523,7 +523,7 @@
IgnoreDefaultLibraryNames="libc" IgnoreDefaultLibraryNames="libc"
ProgramDatabaseFile="$(OutDir)$(PyDllName).pdb" ProgramDatabaseFile="$(OutDir)$(PyDllName).pdb"
BaseAddress="0x1e000000" BaseAddress="0x1e000000"
ImportLibrary="$(OutDir)$(PyDllName).lib" ImportLibrary="$(OutDirPGI)$(PyDllName).lib"
/> />
<Tool <Tool
Name="VCALinkTool" Name="VCALinkTool"
...@@ -598,7 +598,7 @@ ...@@ -598,7 +598,7 @@
IgnoreDefaultLibraryNames="libc" IgnoreDefaultLibraryNames="libc"
ProgramDatabaseFile="$(OutDir)$(PyDllName).pdb" ProgramDatabaseFile="$(OutDir)$(PyDllName).pdb"
BaseAddress="0x1e000000" BaseAddress="0x1e000000"
ImportLibrary="$(OutDir)$(PyDllName).lib" ImportLibrary="$(OutDirPGI)$(PyDllName).lib"
TargetMachine="17" TargetMachine="17"
/> />
<Tool <Tool
......
...@@ -349,6 +349,7 @@ ...@@ -349,6 +349,7 @@
OutputFile="$(OutDir)\pythonw.exe" OutputFile="$(OutDir)\pythonw.exe"
StackReserveSize="2000000" StackReserveSize="2000000"
BaseAddress="0x1d000000" BaseAddress="0x1d000000"
ImportLibrary=""
TargetMachine="1" TargetMachine="1"
/> />
<Tool <Tool
...@@ -421,6 +422,7 @@ ...@@ -421,6 +422,7 @@
OutputFile="$(OutDir)\pythonw.exe" OutputFile="$(OutDir)\pythonw.exe"
StackReserveSize="2000000" StackReserveSize="2000000"
BaseAddress="0x1d000000" BaseAddress="0x1d000000"
ImportLibrary=""
TargetMachine="17" TargetMachine="17"
/> />
<Tool <Tool
...@@ -492,6 +494,7 @@ ...@@ -492,6 +494,7 @@
OutputFile="$(OutDir)\pythonw.exe" OutputFile="$(OutDir)\pythonw.exe"
StackReserveSize="2000000" StackReserveSize="2000000"
BaseAddress="0x1d000000" BaseAddress="0x1d000000"
ImportLibrary=""
TargetMachine="1" TargetMachine="1"
/> />
<Tool <Tool
...@@ -564,6 +567,7 @@ ...@@ -564,6 +567,7 @@
OutputFile="$(OutDir)\pythonw.exe" OutputFile="$(OutDir)\pythonw.exe"
StackReserveSize="2000000" StackReserveSize="2000000"
BaseAddress="0x1d000000" BaseAddress="0x1d000000"
ImportLibrary=""
TargetMachine="17" TargetMachine="17"
/> />
<Tool <Tool
......
...@@ -331,6 +331,7 @@ ...@@ -331,6 +331,7 @@
Name="VCLinkerTool" Name="VCLinkerTool"
GenerateDebugInformation="false" GenerateDebugInformation="false"
SubSystem="1" SubSystem="1"
ImportLibrary=""
/> />
<Tool <Tool
Name="VCALinkTool" Name="VCALinkTool"
...@@ -400,6 +401,7 @@ ...@@ -400,6 +401,7 @@
Name="VCLinkerTool" Name="VCLinkerTool"
GenerateDebugInformation="false" GenerateDebugInformation="false"
SubSystem="1" SubSystem="1"
ImportLibrary=""
TargetMachine="17" TargetMachine="17"
/> />
<Tool <Tool
...@@ -469,6 +471,7 @@ ...@@ -469,6 +471,7 @@
Name="VCLinkerTool" Name="VCLinkerTool"
GenerateDebugInformation="false" GenerateDebugInformation="false"
SubSystem="1" SubSystem="1"
ImportLibrary=""
/> />
<Tool <Tool
Name="VCALinkTool" Name="VCALinkTool"
...@@ -538,6 +541,7 @@ ...@@ -538,6 +541,7 @@
Name="VCLinkerTool" Name="VCLinkerTool"
GenerateDebugInformation="false" GenerateDebugInformation="false"
SubSystem="1" SubSystem="1"
ImportLibrary=""
TargetMachine="17" TargetMachine="17"
/> />
<Tool <Tool
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment