aboutsummaryrefslogtreecommitdiff
path: root/build
diff options
context:
space:
mode:
authorArnoldZokas <arnold.zokas@coderoom.net>2010-12-01 21:45:33 +0000
committerArnoldZokas <arnold.zokas@coderoom.net>2010-12-01 21:45:33 +0000
commit8bd5521e692b1decf541750c337f1e3b07eb8e1d (patch)
tree5408a2f0af0cc580be4a8a297ae11a3fb70c0eb6 /build
parent57afbcf693983b70d3b141d6e4841995e2d3370e (diff)
downloadprotobuf-8bd5521e692b1decf541750c337f1e3b07eb8e1d.tar.gz
protobuf-8bd5521e692b1decf541750c337f1e3b07eb8e1d.tar.bz2
protobuf-8bd5521e692b1decf541750c337f1e3b07eb8e1d.zip
Fixed a bug in '_RunBenchmark' target that caused ProtoBench to throw an exception during execution
Diffstat (limited to 'build')
-rw-r--r--build/BuildBenchmark.ps113
-rw-r--r--build/Common.targets1
-rw-r--r--build/build.csproj2
3 files changed, 15 insertions, 1 deletions
diff --git a/build/BuildBenchmark.ps1 b/build/BuildBenchmark.ps1
new file mode 100644
index 00000000..c301a1ca
--- /dev/null
+++ b/build/BuildBenchmark.ps1
@@ -0,0 +1,13 @@
+write-host `nRunning build. Please wait...
+
+$iterations = 10
+
+for ($i=1; $i -le $iterations; $i++)
+{
+ $sw = [System.Diagnostics.StopWatch]::StartNew()
+ & E:\dotnet-protobufs\build\BuildAll.bat
+ $sw.Stop()
+ $msbuildTotalRunTime += $sw.ElapsedMilliseconds
+}
+
+write-host `nMSBuild average speed over $iterations iterations: ($msbuildTotalRunTime/$iterations) milliseconds \ No newline at end of file
diff --git a/build/Common.targets b/build/Common.targets
index fc611d76..e26bc07a 100644
--- a/build/Common.targets
+++ b/build/Common.targets
@@ -75,6 +75,7 @@
<ItemGroup>
<BenchmarkResources Include="$(BenchmarkProtosDirectory)\google_message1.dat" />
<BenchmarkResources Include="$(BenchmarkProtosDirectory)\google_message2.dat" />
+ <BenchmarkResources Include="$(SourceDirectory)\ProtocolBuffers\bin\$(BuildConfiguration)\Google.ProtocolBuffers.dll" />
<BenchmarkResources Include="$(SourceDirectory)\ProtoBench\bin\$(BuildConfiguration)\ProtoBench.exe" />
</ItemGroup>
diff --git a/build/build.csproj b/build/build.csproj
index 5805b625..50e2207a 100644
--- a/build/build.csproj
+++ b/build/build.csproj
@@ -20,7 +20,7 @@
<!--Tool Paths-->
<ProtocExePath>$(LibDirectory)\protoc.exe</ProtocExePath>
<ProtogenExePath>$(SourceDirectory)\ProtoGen\bin\$(BuildConfiguration)\protogen.exe</ProtogenExePath>
- <ProtoBenchExePath>$(SourceDirectory)\ProtoBench\bin\$(BuildConfiguration)\ProtoBench.exe</ProtoBenchExePath>
+ <ProtoBenchExePath>$(BuildTempDirectory)\ProtoBench.exe</ProtoBenchExePath>
<NUnitExePath>$(LibDirectory)\NUnit 2.2.8.0\nunit-console.exe</NUnitExePath>
<ZipExePath>$(LibDirectory)\7-Zip 9.20\7za.exe</ZipExePath>
</PropertyGroup>