Skip to content
Snippets Groups Projects
Commit 2e1c899f authored by Christian Wulf's avatar Christian Wulf
Browse files

added performance test profiles

parent e780f2d3
No related branches found
No related tags found
No related merge requests found
Showing
with 153 additions and 24 deletions
......@@ -33,11 +33,13 @@
<groupId>org.hamcrest</groupId>
<artifactId>hamcrest-core</artifactId>
<version>1.3</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.hamcrest</groupId>
<artifactId>hamcrest-library</artifactId>
<version>1.3</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>net.kieker-monitoring</groupId>
......@@ -53,11 +55,13 @@
<groupId>ch.qos.logback</groupId>
<artifactId>logback-classic</artifactId>
<version>1.1.2</version>
<scope>runtime</scope>
</dependency>
<dependency>
<groupId>org.codehaus.groovy</groupId>
<artifactId>groovy-all</artifactId>
<version>2.3.6</version>
<scope>runtime</scope>
</dependency>
<dependency>
<groupId>com.google.guava</groupId>
......@@ -79,12 +83,19 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<source>1.6</source>
<target>1.6</target>
</configuration>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>versions-maven-plugin</artifactId>
<version>2.1</version>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-shade-plugin</artifactId>
......@@ -97,7 +108,7 @@
</execution>
</executions>
<configuration>
<finalName>uber-${artifactId}-${version}</finalName>
<finalName>${project.artifactId}-${project.version}</finalName>
</configuration>
</plugin>
</plugins>
......
......@@ -24,7 +24,6 @@ import java.util.List;
import java.util.Map;
import java.util.concurrent.Callable;
import teetime.util.StatisticsUtil;
import teetime.variant.explicitScheduling.framework.concurrent.StageTerminationPolicy;
import teetime.variant.explicitScheduling.framework.concurrent.WorkerThread;
import teetime.variant.explicitScheduling.framework.core.Analysis;
......@@ -33,6 +32,7 @@ import teetime.variant.explicitScheduling.framework.core.Pipeline;
import teetime.variant.explicitScheduling.framework.sequential.MethodCallPipe;
import teetime.variant.explicitScheduling.framework.sequential.QueuePipe;
import teetime.variant.explicitScheduling.stage.NoopFilter;
import util.StatisticsUtil;
import kieker.analysis.AnalysisController;
import kieker.analysis.IAnalysisController;
......
......@@ -34,7 +34,6 @@ import kieker.analysis.stage.StartTimestampFilter;
import kieker.analysis.stage.StopTimestampFilter;
import kieker.common.configuration.Configuration;
import teetime.util.StatisticsUtil;
import teetime.variant.explicitScheduling.examples.throughput.TimestampObject;
import teetime.variant.explicitScheduling.framework.concurrent.WorkerThread;
import teetime.variant.explicitScheduling.framework.core.Analysis;
......@@ -43,6 +42,7 @@ import teetime.variant.explicitScheduling.framework.core.Pipeline;
import teetime.variant.explicitScheduling.framework.sequential.MethodCallPipe;
import teetime.variant.explicitScheduling.framework.sequential.QueuePipe;
import teetime.variant.explicitScheduling.stage.NoopFilter;
import util.StatisticsUtil;
/**
* @author Nils Christian Ehmke
......
......@@ -21,10 +21,10 @@ import java.util.concurrent.Callable;
import org.junit.Test;
import teetime.util.StatisticsUtil;
import teetime.util.StopWatch;
import teetime.variant.explicitScheduling.examples.throughput.TimestampObject;
import test.PerformanceTest;
import util.PerformanceTest;
import util.StatisticsUtil;
import kieker.analysis.examples.ThroughputTimestampAnalysis;
import kieker.analysis.exception.AnalysisConfigurationException;
......
......@@ -7,6 +7,8 @@ import java.util.Map;
import org.junit.Test;
import util.StatisticsUtil;
public class StopWatchTest {
private static final int NUM_ITERATIONS = 1000000;
......
......@@ -20,7 +20,7 @@ import java.util.concurrent.Callable;
import org.junit.Test;
import teetime.util.StopWatch;
import test.PerformanceTest;
import util.PerformanceTest;
/**
* @author Christian Wulf
......
......@@ -21,9 +21,9 @@ import java.util.concurrent.Callable;
import org.junit.Test;
import teetime.util.StatisticsUtil;
import teetime.util.StopWatch;
import test.PerformanceTest;
import util.PerformanceTest;
import util.StatisticsUtil;
/**
* @author Christian Wulf
......
......@@ -20,8 +20,8 @@ import teetime.variant.methodcall.examples.experiment07.MethodCallThoughputTimes
import teetime.variant.methodcall.examples.experiment08.MethodCallThoughputTimestampAnalysis8Test;
import teetime.variant.methodcall.examples.experiment12.MethodCallThoughputTimestampAnalysis12Test;
import teetime.variant.methodcall.examples.experiment13.MethodCallThoughputTimestampAnalysis13Test;
import test.PerformanceResult;
import test.PerformanceTest;
import util.PerformanceResult;
import util.PerformanceTest;
@RunWith(Suite.class)
@SuiteClasses({
......
......@@ -20,8 +20,8 @@ import teetime.variant.methodcall.examples.experiment07.MethodCallThoughputTimes
import teetime.variant.methodcall.examples.experiment08.MethodCallThoughputTimestampAnalysis8Test;
import teetime.variant.methodcall.examples.experiment12.MethodCallThoughputTimestampAnalysis12Test;
import teetime.variant.methodcall.examples.experiment13.MethodCallThoughputTimestampAnalysis13Test;
import test.PerformanceResult;
import test.PerformanceTest;
import util.PerformanceResult;
import util.PerformanceTest;
@RunWith(Suite.class)
@SuiteClasses({
......
......@@ -20,10 +20,10 @@ import static org.junit.Assert.assertEquals;
import org.junit.Test;
import teetime.util.ConstructorClosure;
import teetime.util.StatisticsUtil;
import teetime.variant.explicitScheduling.examples.throughput.TimestampObject;
import test.PerformanceResult;
import test.PerformanceTest;
import util.PerformanceResult;
import util.PerformanceTest;
import util.StatisticsUtil;
/**
* @author Christian Wulf
......
......@@ -19,7 +19,7 @@ import org.junit.Test;
import teetime.util.ConstructorClosure;
import teetime.variant.explicitScheduling.examples.throughput.TimestampObject;
import test.PerformanceTest;
import util.PerformanceTest;
/**
* @author Christian Wulf
......
......@@ -19,7 +19,7 @@ import org.junit.Test;
import teetime.util.ConstructorClosure;
import teetime.variant.explicitScheduling.examples.throughput.TimestampObject;
import test.PerformanceTest;
import util.PerformanceTest;
/**
* @author Christian Wulf
......
......@@ -19,7 +19,7 @@ import org.junit.Test;
import teetime.util.ConstructorClosure;
import teetime.variant.explicitScheduling.examples.throughput.TimestampObject;
import test.PerformanceTest;
import util.PerformanceTest;
/**
* @author Christian Wulf
......
......@@ -19,7 +19,7 @@ import org.junit.Test;
import teetime.util.ConstructorClosure;
import teetime.variant.explicitScheduling.examples.throughput.TimestampObject;
import test.PerformanceTest;
import util.PerformanceTest;
/**
* @author Christian Wulf
......
......@@ -19,7 +19,7 @@ import org.junit.Test;
import teetime.util.ConstructorClosure;
import teetime.variant.explicitScheduling.examples.throughput.TimestampObject;
import test.PerformanceTest;
import util.PerformanceTest;
/**
* @author Christian Wulf
......
......@@ -19,7 +19,7 @@ import org.junit.Test;
import teetime.util.ConstructorClosure;
import teetime.variant.explicitScheduling.examples.throughput.TimestampObject;
import test.PerformanceTest;
import util.PerformanceTest;
/**
* @author Christian Wulf
......
......@@ -19,7 +19,7 @@ import org.junit.Test;
import teetime.util.ConstructorClosure;
import teetime.variant.explicitScheduling.examples.throughput.TimestampObject;
import test.PerformanceTest;
import util.PerformanceTest;
/**
* @author Christian Wulf
......
......@@ -19,7 +19,7 @@ import org.junit.Test;
import teetime.util.ConstructorClosure;
import teetime.variant.explicitScheduling.examples.throughput.TimestampObject;
import test.PerformanceTest;
import util.PerformanceTest;
/**
* @author Christian Wulf
......
......@@ -19,7 +19,7 @@ import org.junit.Test;
import teetime.util.ConstructorClosure;
import teetime.variant.explicitScheduling.examples.throughput.TimestampObject;
import test.PerformanceTest;
import util.PerformanceTest;
/**
* @author Christian Wulf
......
package teetime.variant.methodcallWithPorts.examples;
import static org.junit.Assert.assertEquals;
import java.util.Map;
import java.util.Map.Entry;
import util.PerformanceCheckProfile;
import util.PerformanceResult;
import util.PerformanceTest;
public class ChwHomeComparisonMethodcallWithPorts implements PerformanceCheckProfile {
@Override
public String getCorrespondingPerformanceProfile() {
return "ChwHome";
}
@Override
public void check() {
Map<String, PerformanceResult> performanceResults = PerformanceTest.measurementRepository.performanceResults;
for (Entry<String, PerformanceResult> entry : performanceResults.entrySet()) {
System.out.println("---> " + entry.getKey() + "\n" + entry.getValue());
}
PerformanceResult test1 = performanceResults
.get("testWithManyObjects(teetime.variant.methodcall.examples.experiment01.MethodCallThoughputTimestampAnalysis1Test)");
PerformanceResult test9 = performanceResults
.get("testWithManyObjects(teetime.variant.methodcallWithPorts.examples.experiment09.MethodCallThoughputTimestampAnalysis9Test)");
PerformanceResult test10 = performanceResults
.get("testWithManyObjects(teetime.variant.methodcallWithPorts.examples.experiment10.MethodCallThoughputTimestampAnalysis10Test)");
PerformanceResult test11 = performanceResults
.get("testWithManyObjects(teetime.variant.methodcallWithPorts.examples.experiment11.MethodCallThoughputTimestampAnalysis11Test)");
PerformanceResult test14 = performanceResults
.get("testWithManyObjects(teetime.variant.methodcallWithPorts.examples.experiment14.MethodCallThoughputTimestampAnalysis14Test)");
PerformanceResult test15 = performanceResults
.get("testWithManyObjects(teetime.variant.methodcallWithPorts.examples.experiment15.MethodCallThoughputTimestampAnalysis15Test)");
PerformanceResult test16a = performanceResults
.get("testWithManyObjectsAnd1Thread(teetime.variant.methodcallWithPorts.examples.experiment16.MethodCallThoughputTimestampAnalysis16Test)");
PerformanceResult test16b = performanceResults
.get("testWithManyObjectsAnd2Threads(teetime.variant.methodcallWithPorts.examples.experiment16.MethodCallThoughputTimestampAnalysis16Test)");
PerformanceResult test16c = performanceResults
.get("testWithManyObjectsAnd4Threads(teetime.variant.methodcallWithPorts.examples.experiment16.MethodCallThoughputTimestampAnalysis16Test)");
PerformanceResult test17 = performanceResults
.get("testWithManyObjects(teetime.variant.methodcallWithPorts.examples.experiment17.MethodCallThoughputTimestampAnalysis17Test)");
PerformanceResult test19a = performanceResults
.get("testWithManyObjectsAnd1Thread(teetime.variant.methodcallWithPorts.examples.experiment19.MethodCallThoughputTimestampAnalysis19Test)");
PerformanceResult test19b = performanceResults
.get("testWithManyObjectsAnd2Threads(teetime.variant.methodcallWithPorts.examples.experiment19.MethodCallThoughputTimestampAnalysis19Test)");
PerformanceResult test19c = performanceResults
.get("testWithManyObjectsAnd4Threads(teetime.variant.methodcallWithPorts.examples.experiment19.MethodCallThoughputTimestampAnalysis19Test)");
double value14 = (double) test14.quantiles.get(0.5) / test1.quantiles.get(0.5);
double value10 = (double) test10.quantiles.get(0.5) / test1.quantiles.get(0.5);
double value11 = (double) test11.quantiles.get(0.5) / test1.quantiles.get(0.5);
double value9 = (double) test9.quantiles.get(0.5) / test1.quantiles.get(0.5);
double value15 = (double) test15.quantiles.get(0.5) / test1.quantiles.get(0.5);
double value17 = (double) test17.quantiles.get(0.5) / test1.quantiles.get(0.5);
System.out.println("value14: " + value14);
System.out.println("value10: " + value10);
System.out.println("value11: " + value11);
System.out.println("value9: " + value9);
System.out.println("value15: " + value15);
System.out.println("value17: " + value17);
// until 25.06.2014 (incl.)
// assertEquals(60, (double) test14.quantiles.get(0.5) / test1.quantiles.get(0.5), 5.1);
// assertEquals(14, (double) test10.quantiles.get(0.5) / test1.quantiles.get(0.5), 2.1);
// assertEquals(32, (double) test11.quantiles.get(0.5) / test1.quantiles.get(0.5), 4.1);
// assertEquals(22, (double) test9.quantiles.get(0.5) / test1.quantiles.get(0.5), 2.1);
// assertEquals(44, (double) test15.quantiles.get(0.5) / test1.quantiles.get(0.5), 4.1);
// assertEquals(39, (double) test17.quantiles.get(0.5) / test1.quantiles.get(0.5), 4.1);
// since 26.06.2014 (incl.)
// assertEquals(76, value14, 5.1); // +16
// assertEquals(26, value10, 2.1); // +14
// assertEquals(44, value11, 4.1); // +12
// assertEquals(36, value9, 2.1); // +14
// assertEquals(44, value15, 4.1); // +0
// assertEquals(53, value17, 4.1); // +14
// // since 04.07.2014 (incl.)
// assertEquals(86, value14, 5.1); // +16
// assertEquals(26, value10, 2.1); // +0
// assertEquals(41, value11, 4.1); // -3
// assertEquals(42, value9, 2.1); // +6
// assertEquals(44, value15, 4.1); // +0
// assertEquals(53, value17, 4.1); // +0
// since 11.08.2014 (incl.)
assertEquals(103, value14, 5.1); // +17
assertEquals(47, value10, 2.1); // +21
assertEquals(41, value11, 4.1); // -3
assertEquals(42, value9, 2.1); // +6
assertEquals(44, value15, 4.1); // +0
assertEquals(53, value17, 4.1); // +0
// below results vary too much, possibly due to the OS' scheduler
// assertEquals(RESULT_TESTS_16, (double) test16a.quantiles.get(0.5) / test1.quantiles.get(0.5), 5.1);
// assertEquals(RESULT_TESTS_16, (double) test16b.quantiles.get(0.5) / test1.quantiles.get(0.5), 5.1);
// assertEquals(RESULT_TESTS_16, (double) test16c.quantiles.get(0.5) / test1.quantiles.get(0.5), 5.1);
//
// assertEquals(RESULT_TESTS_19, (double) test19a.quantiles.get(0.5) / test1.quantiles.get(0.5), 5.1);
// assertEquals(RESULT_TESTS_19, (double) test19b.quantiles.get(0.5) / test1.quantiles.get(0.5), 5.1);
// assertEquals(RESULT_TESTS_19, (double) test19c.quantiles.get(0.5) / test1.quantiles.get(0.5), 5.1);
// check speedup
assertEquals(2, (double) test16a.overallDurationInNs / test16b.overallDurationInNs, 0.3);
assertEquals(2.5, (double) test16a.overallDurationInNs / test16c.overallDurationInNs, 0.2);
assertEquals(2, (double) test19a.overallDurationInNs / test19b.overallDurationInNs, 0.3);
assertEquals(2.5, (double) test19a.overallDurationInNs / test19c.overallDurationInNs, 0.3);
}
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment