use of org.openjdk.jmh.runner.options.OptionsBuilder in project poi by apache.
the class AddImageBench method main.
public static void main(String[] args) throws RunnerException {
Options opt = new OptionsBuilder().include(".*" + AddImageBench.class.getSimpleName() + ".*").addProfiler(StackProfiler.class).addProfiler(GCProfiler.class).forks(1).build();
new Runner(opt).run();
}
use of org.openjdk.jmh.runner.options.OptionsBuilder in project hive by apache.
the class MapJoinOneStringKeyBench method main.
// -----------------------------------------------------------------------------------------------
public static void main(String[] args) throws RunnerException {
Options opt = new OptionsBuilder().include(".*" + MapJoinOneStringKeyBench.class.getSimpleName() + ".*").build();
new Runner(opt).run();
}
use of org.openjdk.jmh.runner.options.OptionsBuilder in project hive by apache.
the class VectorGroupByOperatorBench method main.
/*
* ============================== HOW TO RUN THIS TEST: ====================================
*
* You can run this test:
*
* a) Via the command line:
* $ mvn clean install
* $ java -jar target/benchmarks.jar VectorGroupByOperatorCountBench -prof perf -f 1 (Linux)
* $ java -jar target/benchmarks.jar VectorGroupByOperatorCountBench -prof perfnorm -f 3 (Linux)
* $ java -jar target/benchmarks.jar VectorGroupByOperatorCountBench -prof perfasm -f 1 (Linux)
* $ java -jar target/benchmarks.jar VectorGroupByOperatorCountBench -prof gc -f 1 (allocation counting via gc)
* $ java -jar target/benchmarks.jar VectorGroupByOperatorBench -p hasNulls=true -p isRepeating=false -p aggregation=bloom_filter -p processMode=HASH -p evalMode=PARTIAL1
* $ java -agentlib:jdwp=transport=dt_socket,address=127.0.0.1:6006,suspend=y,server=y -jar target/benchmarks.jar VectorGroupByOperatorBench
*/
public static void main(String[] args) throws RunnerException {
Options opt = new OptionsBuilder().include(VectorGroupByOperatorBench.class.getSimpleName()).addProfiler(LinuxPerfProfiler.class).addProfiler(LinuxPerfNormProfiler.class).addProfiler(LinuxPerfAsmProfiler.class).build();
new Runner(opt).run();
}
use of org.openjdk.jmh.runner.options.OptionsBuilder in project ignite by apache.
the class JmhCacheLocksBenchmark method main.
/**
* Run benchmarks.
*
* @param args Arguments.
* @throws Exception If failed.
*/
public static void main(String[] args) throws Exception {
final String simpleClsName = JmhCacheLocksBenchmark.class.getSimpleName();
final int threads = 4;
final boolean client = true;
final CacheAtomicityMode atomicityMode = CacheAtomicityMode.TRANSACTIONAL;
final CacheWriteSynchronizationMode writeSyncMode = CacheWriteSynchronizationMode.FULL_SYNC;
final String output = simpleClsName + "-" + threads + "-threads" + "-" + (client ? "client" : "data") + "-" + atomicityMode + "-" + writeSyncMode;
final Options opt = new OptionsBuilder().threads(threads).include(simpleClsName).output(output + ".jmh.log").jvmArgs("-Xms1g", "-Xmx1g", "-XX:+UnlockCommercialFeatures", JmhIdeBenchmarkRunner.createProperty(PROP_ATOMICITY_MODE, atomicityMode), JmhIdeBenchmarkRunner.createProperty(PROP_WRITE_SYNC_MODE, writeSyncMode), JmhIdeBenchmarkRunner.createProperty(PROP_DATA_NODES, 4), JmhIdeBenchmarkRunner.createProperty(PROP_CLIENT_MODE, client)).build();
new Runner(opt).run();
}
use of org.openjdk.jmh.runner.options.OptionsBuilder in project ignite by apache.
the class JmhWaitStategyBenchmark method main.
/**
* Benchmark runner
*/
public static void main(String[] args) throws RunnerException {
List<String> policies = Arrays.asList("inc", "dec", "r25", "r50", "r75");
int[] threads = { 2, 4, 8, 16, 32 };
List<RunResult> results = new ArrayList<>();
for (String policy : policies) {
for (int thread : threads) {
ChainedOptionsBuilder builder = new OptionsBuilder().jvmArgs().timeUnit(TimeUnit.MILLISECONDS).measurementIterations(10).measurementTime(TimeValue.seconds(20)).warmupIterations(5).warmupTime(TimeValue.seconds(10)).jvmArgs("-Dbench.exp.policy=" + policy).forks(1).threads(thread).mode(Mode.Throughput).include(JmhWaitStategyBenchmark.class.getSimpleName());
results.addAll(new Runner(builder.build()).run());
}
}
for (RunResult result : results) {
BenchmarkParams params = result.getParams();
Collection<String> args1 = params.getJvmArgs();
for (String s : args1) {
System.out.print(s.substring(s.length() - 3, s.length()));
System.out.print(" x ");
}
System.out.print(params.getThreads());
System.out.print("\t\t");
System.out.println(result.getPrimaryResult().toString());
}
}
Aggregations