8081734: ConcurrentHashMap/ConcurrentAssociateTest.java, times out 90% of time on sparc with 256 cpu.
Reviewed-by: chegar
--- a/jdk/test/java/util/concurrent/ConcurrentHashMap/ConcurrentAssociateTest.java Mon Jul 20 13:11:20 2015 -0700
+++ b/jdk/test/java/util/concurrent/ConcurrentHashMap/ConcurrentAssociateTest.java Mon Jul 20 15:13:50 2015 -0700
@@ -120,7 +120,8 @@
}
};
- int ps = Runtime.getRuntime().availableProcessors();
+ // Bound concurrency to avoid degenerate performance
+ int ps = Math.min(Runtime.getRuntime().availableProcessors(), 32);
Stream<CompletableFuture> runners = IntStream.range(0, ps)
.mapToObj(i -> sr.get())
.map(CompletableFuture::runAsync);