8206007: nsk/jdb/exclude001 test is taking a long time on some builds
Reviewed-by: cjplummer, sspitsyn
--- a/test/hotspot/jtreg/ProblemList.txt Thu Jul 12 13:32:45 2018 -0700
+++ b/test/hotspot/jtreg/ProblemList.txt Thu Jul 12 10:41:44 2018 -0400
@@ -166,7 +166,6 @@
vmTestbase/vm/mlvm/indy/func/jvmti/mergeCP_indy2manyDiff_b/TestDescription.java 8013267 generic-all
vmTestbase/vm/mlvm/indy/func/jvmti/mergeCP_indy2manySame_b/TestDescription.java 8013267 generic-all
-vmTestbase/nsk/jdb/exclude/exclude001/exclude001.java 8197938 windows-all
vmTestbase/nsk/jdwp/ThreadReference/ForceEarlyReturn/forceEarlyReturn001/forceEarlyReturn001.java 7199837 generic-all
--- a/test/hotspot/jtreg/vmTestbase/nsk/jdb/exclude/exclude001/exclude001.java Thu Jul 12 13:32:45 2018 -0700
+++ b/test/hotspot/jtreg/vmTestbase/nsk/jdb/exclude/exclude001/exclude001.java Thu Jul 12 10:41:44 2018 -0400
@@ -34,13 +34,13 @@
* The debuggee program (exclude001a.java) starts three
* addional threads of MyThread class. The 'run' method of these
* threads invokes java.lang.System.currentTimeMillis() and
- * com.sun.jdi.Bootstrap.virtualMachineManager() methods.
+ * sun.util.calendar.Gregorian() methods.
* There are three test cases:
* - block all exclude filter;
* - modified exclude filter allowing tracing events for java.* methods,
* which is set with 'exclude javax.*,sun.*,com.sun.*,jdk.*' command;
- * - modified exclude filter allowing tracing events for com.sun.* methods,
- * which is set with 'exclude java.*,javax.*,sun.*,jdk.*' command.
+ * - modified exclude filter allowing tracing events for sun.* methods,
+ * which is set with 'exclude java.*,javax.*,com.sun.*,jdk.*' command.
* - non-modified, predefined exclude filter;
* - modified exclude filter allowing tracing events for java.* methods,
* which is set with 'exclude javax.*,sun.*,com.sun.*' command;
@@ -102,7 +102,7 @@
static final String DEBUGGEE_THREAD = PACKAGE_NAME + "." + MYTHREAD;
static final String JAVA_CORE_METHOD = "java.lang.System.currentTimeMillis";
- static final String COM_SUN_METHOD = "com.sun.jdi.Bootstrap.virtualMachineManager";
+ static final String SUN_METHOD = "sun.util.calendar.Gregorian";
protected void runCases() {
String[] reply;
@@ -152,8 +152,8 @@
case 1: // allow java.*
reply = jdb.receiveReplyFor(JdbCommand.exclude + "javax.*,sun.*,com.sun.*,jdk.*");
break;
- case 2: // allow com.sun.*
- reply = jdb.receiveReplyFor(JdbCommand.exclude + "java.*,javax.*,sun.*,jdk.");
+ case 2: // allow sun.*
+ reply = jdb.receiveReplyFor(JdbCommand.exclude + "java.*,javax.*,com.sun.*,jdk.");
break;
}
@@ -172,12 +172,12 @@
}
}
- count = grep.find(COM_SUN_METHOD);
+ count = grep.find(SUN_METHOD);
if (count > 0) {
if (testCase == 2) {
comTraced = true;
} else {
- log.complain("Trace message for excluded method: " + COM_SUN_METHOD);
+ log.complain("Trace message for excluded method: " + SUN_METHOD);
}
}
@@ -202,7 +202,7 @@
success = false;
}
if (!comTraced) {
- log.complain("There were no tracing events for " + COM_SUN_METHOD + "() method while turned off filter");
+ log.complain("There were no tracing events for " + SUN_METHOD + "() method while turned off filter");
success = false;
}
if (!nskTraced) {
--- a/test/hotspot/jtreg/vmTestbase/nsk/jdb/exclude/exclude001/exclude001a.java Thu Jul 12 13:32:45 2018 -0700
+++ b/test/hotspot/jtreg/vmTestbase/nsk/jdb/exclude/exclude001/exclude001a.java Thu Jul 12 10:41:44 2018 -0400
@@ -29,7 +29,7 @@
import java.io.*;
-import com.sun.jdi.*;
+import java.util.*;
/* This is debuggee aplication */
@@ -89,6 +89,6 @@
long time = java.lang.System.currentTimeMillis();
- VirtualMachineManager vmm = com.sun.jdi.Bootstrap.virtualMachineManager();
+ String caltype = GregorianCalendar.getInstance().getCalendarType();
}
}