We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent f6021a9 commit 0e2a285Copy full SHA for 0e2a285
test/hotspot/jtreg/testlibrary/ctw/src/sun/hotspot/tools/ctw/CtwRunner.java
@@ -172,8 +172,14 @@ private void startCtwforAllClasses() {
172
173
long classStart = start(totalClassCount);
174
long classStop = stop(totalClassCount);
175
-
176
long classCount = classStop - classStart;
+
177
+ boolean allowZeroClassCount = Boolean.getBoolean("sun.hotspot.tools.ctw.allow_zero_class_count");
178
+ if (allowZeroClassCount && totalClassCount == 0L) {
179
+ System.out.println("WARN: " + target + "(at " + targetPath + ") has no classes. Ignoring.");
180
+ return;
181
+ }
182
183
Asserts.assertGreaterThan(classCount, 0L,
184
target + "(at " + targetPath + ") does not have any classes");
185
0 commit comments