9 * This code is distributed in the hope that it will be useful, but WITHOUT
10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
12 * version 2 for more details (a copy is included in the LICENSE file that
13 * accompanied this code).
14 *
15 * You should have received a copy of the GNU General Public License version
16 * 2 along with this work; if not, write to the Free Software Foundation,
17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
18 *
19 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
20 * or visit www.oracle.com if you need additional information or have any
21 * questions.
22 */
23
24 /**
25 * @test
26 * @bug 8022595
27 * @summary JSR292: deadlock during class loading of MethodHandles, MethodHandleImpl & MethodHandleNatives
28 * @library /testlibrary
29 * @run main/othervm ConcurrentClassLoadingTest
30 */
31 import com.oracle.java.testlibrary.Utils;
32 import java.util.ArrayList;
33 import java.util.Arrays;
34 import java.util.List;
35 import java.util.Random;
36 import java.util.concurrent.BrokenBarrierException;
37 import java.util.concurrent.CyclicBarrier;
38
39 public class ConcurrentClassLoadingTest {
40 int numThreads = 0;
41 CyclicBarrier l;
42 private static final Random rand = Utils.getRandomInstance();
43
44 public static void main(String[] args) throws Throwable {
45 ConcurrentClassLoadingTest test = new ConcurrentClassLoadingTest();
46 test.parseArgs(args);
47 test.run();
48 }
|
9 * This code is distributed in the hope that it will be useful, but WITHOUT
10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
12 * version 2 for more details (a copy is included in the LICENSE file that
13 * accompanied this code).
14 *
15 * You should have received a copy of the GNU General Public License version
16 * 2 along with this work; if not, write to the Free Software Foundation,
17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
18 *
19 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
20 * or visit www.oracle.com if you need additional information or have any
21 * questions.
22 */
23
24 /**
25 * @test
26 * @bug 8022595
27 * @summary JSR292: deadlock during class loading of MethodHandles, MethodHandleImpl & MethodHandleNatives
28 * @library /testlibrary
29 * @build com.oracle.java.testlibrary.*
30 * @run main/othervm ConcurrentClassLoadingTest
31 */
32 import com.oracle.java.testlibrary.Utils;
33 import java.util.ArrayList;
34 import java.util.Arrays;
35 import java.util.List;
36 import java.util.Random;
37 import java.util.concurrent.BrokenBarrierException;
38 import java.util.concurrent.CyclicBarrier;
39
40 public class ConcurrentClassLoadingTest {
41 int numThreads = 0;
42 CyclicBarrier l;
43 private static final Random rand = Utils.getRandomInstance();
44
45 public static void main(String[] args) throws Throwable {
46 ConcurrentClassLoadingTest test = new ConcurrentClassLoadingTest();
47 test.parseArgs(args);
48 test.run();
49 }
|