提交 b6500a6d 编写于 作者: D dpochepk

8068385: [TESTBUG]...

8068385: [TESTBUG] hotspot/test/compiler/codecache/jmx/PoolsIndependenceTest.java sometimes fails(unstable behaviour)
Summary: fixing unstable behaviour of 2 tests
Reviewed-by: iignatyev
上级 cbd03dda
......@@ -98,11 +98,13 @@ public class PoolsIndependenceTest implements NotificationListener {
return false;
});
for (BlobType bt : BlobType.getAvailable()) {
int expectedNotificationsAmount = bt.equals(btype) ? 1 : 0;
Asserts.assertEQ(counters.get(bt.getMemoryPool().getName()).get(),
expectedNotificationsAmount, String.format("Unexpected "
+ "amount of notifications for pool: %s",
bt.getMemoryPool().getName()));
if (CodeCacheUtils.isCodeHeapPredictable(bt)) {
int expectedNotificationsAmount = bt.equals(btype) ? 1 : 0;
Asserts.assertEQ(counters.get(bt.getMemoryPool().getName()).get(),
expectedNotificationsAmount, String.format("Unexpected "
+ "amount of notifications for pool: %s",
bt.getMemoryPool().getName()));
}
}
try {
((NotificationEmitter) ManagementFactory.getMemoryMXBean()).
......
......@@ -52,7 +52,9 @@ public class ThresholdNotificationsTest implements NotificationListener {
public static void main(String[] args) {
for (BlobType bt : BlobType.getAvailable()) {
new ThresholdNotificationsTest(bt).runTest();
if (CodeCacheUtils.isCodeHeapPredictable(bt)) {
new ThresholdNotificationsTest(bt).runTest();
}
}
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册