added static {

Jvm.init();
          }
This commit is contained in:
Rob Austin
2021-01-27 16:05:11 +00:00
parent 06451ca557
commit 5e21c4e287
@@ -16,6 +16,7 @@
package examples.portfolio;
import net.openhft.chronicle.core.Jvm;
import net.openhft.chronicle.core.values.LongValue;
import net.openhft.chronicle.map.ChronicleMap;
import net.openhft.chronicle.map.ChronicleMapBuilder;
@@ -36,6 +37,10 @@ public class PortfolioValueTest {
private static final int nThreads = Runtime.getRuntime().availableProcessors();
private static final int nRepetitions = 11; // 10 for computing average, throwing away the first one (warmup)
static {
Jvm.init();
}
private static void computeValue(final ChronicleMap<LongValue, PortfolioAssetInterface> cache) throws ExecutionException, InterruptedException {
computeValueUsingIterator(cache);
}