Tue, 12 Feb 2013 07:39:42 -0800
8002169: TEST_BUG: compiler/7009359/Test7009359.java sometimes times out
Summary: make the test less prone to timeout by reducing the amount of iteration and allowing main to be compiled
Reviewed-by: jrose
test/compiler/7009359/Test7009359.java | file | annotate | diff | comparison | revisions |
1.1 --- a/test/compiler/7009359/Test7009359.java Mon Feb 11 14:47:04 2013 -0800 1.2 +++ b/test/compiler/7009359/Test7009359.java Tue Feb 12 07:39:42 2013 -0800 1.3 @@ -1,5 +1,5 @@ 1.4 /* 1.5 - * Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved. 1.6 + * Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved. 1.7 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 1.8 * 1.9 * This code is free software; you can redistribute it and/or modify it 1.10 @@ -27,13 +27,13 @@ 1.11 * @bug 7009359 1.12 * @summary HS with -XX:+AggressiveOpts optimize new StringBuffer(null) so it does not throw NPE as expected 1.13 * 1.14 - * @run main/othervm -Xbatch -XX:+IgnoreUnrecognizedVMOptions -XX:+OptimizeStringConcat -XX:CompileCommand=exclude,Test7009359,main Test7009359 1.15 + * @run main/othervm -Xbatch -XX:+IgnoreUnrecognizedVMOptions -XX:+OptimizeStringConcat -XX:CompileCommand=dontinline,Test7009359,stringmakerBUG Test7009359 1.16 * 1.17 */ 1.18 1.19 public class Test7009359 { 1.20 public static void main (String[] args) { 1.21 - for(int i = 0; i < 1000000; i++) { 1.22 + for(int i = 0; i < 100000; i++) { 1.23 if(!stringmakerBUG(null).equals("NPE")) { 1.24 System.out.println("StringBuffer(null) does not throw NPE"); 1.25 System.exit(97);