< prev index next >

test/hotspot/jtreg/vmTestbase/nsk/stress/strace/strace001.java

Print this page
rev 56807 : [mq]: 8232684-v2


 278                 test.achivedCount++;
 279             }
 280 
 281             int alltime = 0;
 282             while (!strace001.isLocked) {
 283                 synchronized (test) {
 284                     try {
 285                         test.wait(1);
 286                         alltime++;
 287                     } catch (InterruptedException e) {
 288                         strace001.complain("" + e);
 289                     }
 290                     if (alltime > strace001.waitTime) {
 291                         throw new Failure("out of wait time");
 292                     }
 293                 }
 294             }
 295         }
 296 
 297         if (strace001.DEPTH - currentDepth > 0) {
 298             yield();
 299             recursiveMethod();
 300         }
 301 
 302         currentDepth--;
 303     }
 304 }


 278                 test.achivedCount++;
 279             }
 280 
 281             int alltime = 0;
 282             while (!strace001.isLocked) {
 283                 synchronized (test) {
 284                     try {
 285                         test.wait(1);
 286                         alltime++;
 287                     } catch (InterruptedException e) {
 288                         strace001.complain("" + e);
 289                     }
 290                     if (alltime > strace001.waitTime) {
 291                         throw new Failure("out of wait time");
 292                     }
 293                 }
 294             }
 295         }
 296 
 297         if (strace001.DEPTH - currentDepth > 0) {
 298             Thread.yield();
 299             recursiveMethod();
 300         }
 301 
 302         currentDepth--;
 303     }
 304 }
< prev index next >